mice.impute.rf(y, ry, x, ntree = 100, ...)
y
(TRUE
=
observed, FALSE
= missing)length(y)
rows and
p
columns containing complete covariates.randomForest()
and
randomForest:::randomForest.default()
.sum(!ry)
with imputationsy
by random forests. The method calls
randomForrest()
which implements Breiman's random
forest algorithm (based on Breiman and Cutler's original
Fortran code) for classification and regression. See
Appendix A.1 of Doove et al. (2014) for the definition of
the algorithm used. An alternative implementation was
independently developed by Shah et al (2014), and is
available in the package CALIBERrfimpute
.Shah, A.D., Bartlett, J.W., Carpenter, J., Nicholas, O., Hemingway, H. (2014), Comparison of random forest and parametric imputation models for imputing missing data using MICE: A CALIBER study. American Journal of Epidemiology, doi: 10.1093/aje/kwt312.
Van Buuren, S.(2012), Flexible imputation of missing data, Boca Raton, FL: Chapman & Hall/CRC.
mice
, mice.impute.cart
,
randomForest
,
mice.impute.rfcat
,
mice.impute.rfcont
library("lattice")
imp <- mice(nhanes2, meth = "rf", ntree = 3)
plot(imp)
Run the code above in your browser using DataLab