[R] Multiple imputation on subgroups

Weidong Gu anopheles123 at gmail.com
Mon Oct 10 16:51:21 CEST 2011


An ad-hoc method is to impute missing scores of the whole data set
including subgroup1, then change imputed scores in subgroup1 into NA.

Weidong Gu

On Mon, Oct 10, 2011 at 5:35 AM, Sarah <s1327720 at student.rug.nl> wrote:
> Dear R-users,
>
> I want to multiple impute missing scores, but only for a few subgroups in my
> data (variable 'subgroups':  only impute for subgroups 2 and 3).
> Does anyone knows how to do this in MICE?
>
> This is my script for the multiple imputation:
> imp <- mice(data, m=20, predictorMatrix=pred, post=post,
>        method=c("", "", "", "", "","norm", "norm","norm","norm","norm","norm"),
>        maxit=20)       .
>
> The final analysis should be on the dataset as a whole, so with subgroups 2
> and 3 with observed and imputed values, and for subgroup 1 with observed
> values only (and missing scores).
>
> Thanks.
>
> --
> View this message in context: http://r.789695.n4.nabble.com/Multiple-imputation-on-subgroups-tp3889664p3889664.html
> Sent from the R help mailing list archive at Nabble.com.
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



More information about the R-help mailing list