Git Product home page Git Product logo

icarus's People

Contributors

haroine avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

icarus's Issues

Improve syntax of margin input with lists

The idea is to change the recommended margin input method to something like:

marginList <- list(
"categ" = c(0.35, 0.4, 0.25),
"sexe" = c(0.60, 0.40),
"service" = c(0.45, 0.55),
"salaire" = 470000
)

  • Add tests with the list method, with categorical and continuous variables

  • Modify addMargin

  • marginMatrix becomes an ambiguous parameter name: consider changing it (but ensure retrocompatibility!)

  • Change recommended way of integrating margins in the docs

Thanks to Toby Hocking for the suggestion!

Calibration on non-linear totals

Following the linearization formulas of Dell et. al: http://www.crest.fr/ckfinder/userfiles/files/Pageperso/xdhault/doc_JMS.pdf, Icarus could support calibration on non-linear totals such as quantiles, Gini indices, etc.

Due to the approximations, we would have to come up with an iterative procedure that would check that the final estimates correspond to the true value.

Some functions of the gustave package https://github.com/martinchevalier/gustave could be reused

Make new ponderation from scratch

Bonjour,
Une question est il possible dans Icarus de créer de nouvelles valeurs de pondération à partir de zéro ?
Je veux dire par là ne pas avoir de pondération a priori ?

English version below :
Hi,
Just a litle ask, : Is it possible to create ponderation weight from scratch in icarus ?

Calibration with raking method works with CALMAR2 SAS but not with Icarus in R

Hi, I need to perform a calibration using margins on a dataset of observations.
Now this operation is performed using the macro CALMAR2 in SAS, I tried using the Icarus package but the algorithm doesn't converge.
I checked all the input parameters and they are the same that I use in SAS, with the 'linear' method the algorithm converges but with the raking no.

Make regroupCalibrationModalities have no side effects

Return a list instead and suggest in the docs to use operator %<-% to facilitate multiple assignment of returned calibrationMatrix and marginMatrix.

Be careful to not deprecate the side effects functionality too fast.

Bounds not working

When I run the following, I get minimum and maximum weight values that are outside the bounds. Sorry if I've misunderstood the documentation...

library(icarus)
mar1 <- c("categ",3,80,90,60)
mar2 <- c("sexe",2,140,90,0)
mar3 <- c("service",2,100,130,0)
mar4 <- c("salaire", 0, 470000,0,0)
margins <- rbind(mar1, mar2, mar3, mar4)
wCal <- calibration(data = data_ex2,
marginMatrix = margins,
colWeights="poids",
method = "logit",
bounds = c(3, 38),
description=FALSE)
range(wCal)

Before calibration donne des résultats étranges

Bonjour,

Nous avons un problème de convergence avec un nombre assez important de contraintes (environ 800-900: 238*17).
Les résultats de la fonction calibration ont l'air assez cohérent si ce n'est pour une des strates (celle avec 17 options) où l'on obtient:

  • Before Calibration : que des valeurs nulles sauf une à 1,08
  • After Calibration: que des valeurs nulles sauf la même à 1,07
  • Margin: Correct correspondants aux poids respectifs des différentes modalités de la Strate dans la marginMatrix

Lorsque nous utiliser la méthode avec pénalité en relâchant les contraintes sur cette strate étrange, nous obtenons rigoureusement le même résultat.

Nous ne parvenons pas à en déterminer la cause.

Pourtant la convergence a l'air bonne à plusieurs égards. Centrée autour de 1 avec des margins matrix avant-après très similaires.

Auriez-vous un avis sur notre problème?
Merci d'avance.

C++ implementation for min bounds

Currently, implementation of min bounds calibration is purely R and (relying on slam's sparse matrices and Rglpk).

Implementing the algorithm in C++ could:

  • decrease the execution time
  • decrease memory usage
  • decrease the number of dependencies required to make minimum calibration work

Percentages for categorical variables

Percentages in Icarus have now to be entered with a sum equal to 1 (e.g. "0.4 - 0.2 - 0.4"), whereas in Calmar and Calmar 2, percentages sum have to be equal to 100 (e.g. "40 - 20 - 40").

Icarus should support both input types as long as parameter pct is set to TRUE.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.