I'm having a hard time understanding how can I compare a GLM with a GLMM, knowing that I probably can't compare their AIC as glmer from lme4 probably computes the maximum likelihood differently from glm.
However, I wondered if I could find my way using ANOVA that way:
> anova(md.mm, md.logistic1) Data: d.binary Models: md.logistic1: Precision ~ temps + RunProfile md.mm: Precision ~ temps + RunProfile + (1 | trainId) Df AIC BIC logLik deviance Chisq Chi Df Pr(>Chisq) md.logistic1 8 1225.6 1276.7 -604.80 1209.6 md.mm 9 1225.3 1282.7 -603.63 1207.3 2.3451 1 0.1257
But still, I'm not really sure how to conclude:
Is it a proper way to compare those two models ?
Can I accurately conclude that considering the degrees of freedom and the not-significant p-value, I should consider the GLM model instead of the GLMM one ?
I read that the best way to conclude regarding the significance of random effects in the GLMM model would be to test the null hypothesis about zero variances. I read in the GLMM FAQ that it's possible to test that using the RLRsim package but that only works for lmer models. Is there a way to test it for GLMMs ?