I am doing a MI on a categorical variable with MICE for descriptive statistics(counts(proportion) in each level).
How can i get the pooled standard error for the proportions in each level?
could this be done with pool.scalar
?
What i have done:
##
data1<-nhanes2
## MI with mice
imp.data <- mice (data = data1, m = 5, maxit = 10, seed = 12345, method = "cart")
## to get all the imputed data sets into one
data2<-complete(imp.data, "long")
## get the counts for each level
counts<-count(data2$hyp)
### Average for all imputed data sets m=5
counts$n<-counts$freq/5