Extract posterior estimate and credible intervals for random effect for lme4 model in R
问题 I need to extract the posterior estimates and intervals for a random effect from my model. For illustrative purposes, a similar dataset to the one I am using would be the ChickWeight dataset in base R. The way I extract the posterior estimates and intervals for my fixed effects is like so: #load package library(lme4) #model m.surv<-lmer(weight ~ Time + Diet + (1|Chick), data=ChickWeight) #load packages library(MCMCglmm) library(arm) #set up for fixed effects sm.surv<-sim(m.surv) smfixef.surv