Displaying 1 result from an estimated 1 matches for "rubin1987".
2016 Apr 10
0
logistic regression with package 'mice'
...ogistic regression on imputed data:
library(mice)
imp <- mice(nhanes)
# logistic regression on the imputed data
fit <- glm.mids((hyp==2)~bmi+chl, data=imp, family = binomial)
summary(fit)
summary(pool(fit)) ### pool averaging across all imputed dataset
summary(pool(fit, method = "rubin1987")) ### pool across all imputed
dataset
### odds ratio
su <- summary(pool(fit, method = "rubin1987"))[,c(1,6,7)]
stime <- data.frame(exp(su))
names(stime) <- c("OR", "95% low", "95% high")
options(scipen=999)
stime
options(scipen=1)
[[a...