I know that in order to test whether a random effect has a significant impact on a model it's necessary to sequentially remove one random effect at a time and check each model pair with
anova() function in lme4 package or through
exactLRT() function included in RLRsim package.
However this functions works me well when I worked with lmer() function but not in glmer() function.
In detail, I want to discover if the inclusion of a random effect in my model is significant or not.
model0<-glm(Feed_kg_DM_day~Week, data=dietdef2, family=gaussian(link=log)) model1<-glmer(Feed_kg_DM_day~Week+(1|rat), data=dietdef2, family=gaussian(link=log))
If I perform anova(model0, model1) doesn't show me the p-value:
Analysis of Deviance Table Model: gaussian, link: log Response: Feed_kg_DM_day Terms added sequentially (first to last) Df Deviance Resid. Df Resid. Dev NULL 2756 1119.1 Week 14 1.5985 2742 1117.5
How can I know that the effect of random variable is significant?
Thanks a lot,