1
$\begingroup$

I'm having a dataset with over 90k records and 28 variables. About 13 of these variables are binary variables and each of these 13 variables have around 40k missing values.

Please suggest some imputation techniques that would be appropriate/reliable for binary variables specifically. I tried imputing all these missing values with 0. However the classification model results aren't satisfactory.

$\endgroup$
1
  • 1
    $\begingroup$ What kind of model are you using? Do you know the mechanism behind the missingness? $\endgroup$ Commented Oct 16, 2023 at 0:45

1 Answer 1

1
$\begingroup$

You would be better off using something like multiple imputation. There is a package in R called mice for this purpose. The imputation will essentially fill in the value that is normally approximated when the variable to be imputed has complete cases with other variables. There is a nice vignette below on the method. However, be warned that unlike a lot if objects in R, mids and mira objects derived from these kinds of packages lose a fair amount of functionality across packages, so be wary ahead of time which functions are easy to work with and which arent.

https://www.gerkovink.com/miceVignettes/

$\endgroup$
2
  • $\begingroup$ The distribution of imputed values will not be normal at all for a binary variable! MICE allows for different-shaped distributions to fit different kinds of variables for which values are imputed. $\endgroup$
    – rolando2
    Commented Feb 14 at 17:45
  • 2
    $\begingroup$ The main idea is to use predictive mean matching to guarantee that the distribution of imputed values is realistic, i.e., it mirrors that of the real data but with some adjustments. In addition to mice, check out the R Hmisc package aregImpute function which also imputes multi-category variables. mice doesn’t work correlation for those with the version currently in CRAN, as it assumes the categories are ordered. $\endgroup$ Commented Feb 15 at 12:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.