I read that lmer can handle independent (often labeled as crossed) random effects in mixed models. It seems to be possible with MCMCglmm as long as groups for the random effects are uniquely labeled. I use the "Penicillin" data in the lme4-package to compare both approaches:
library(lme4)
library(MCMCglmm)
str(Penicillin)
attach(Penicillin)
ml <- lmer(diameter~ 1 + (1|plate)+ (1|sample))
summary(ml)
mcmc <- MCMCglmm(diameter~ 1, random=~ plate + sample,verbose=F, nitt=110000,burn=10000,thin=10,data=Penicillin)
summary(mcmc)
Why are the result for the plate-variance differ by a large amount? Is it because MCMCglmm applies Gibbs sampling? Or is MCMCglmm doing something else here, instead of fitting independent random effects?
plateand not thesample? In any case I think you want to checkplot(density((mcmc$VCV[,"sample"]))for excessive skewness; maybe the median will do a better job. Check this link too: http://stats.stackexchange.com/questions/126122/what-is-going-on-in-an-mcmc-chain/126137#126137 for information on the MCMC part ofMCMCglmm. – usεr11852 Jan 20 '15 at 12:34