[R-sig-ME] Variance explained by random factor
Ken Beath
ken at kjbeath.com.au
Thu Aug 14 11:10:10 CEST 2008
On 14/08/2008, at 1:17 AM, Renwick, A. R. wrote:
>
> I am currently trying to run a lmer model with poisson
> distrubution. I tested the model with a model without the random
> effect and it inferred that I should include the random effect:
>
> ma1<-glm(RoundedOverlap~sess+breedfem,family=poisson,data=Male)
> mixed<-lmer(RoundedOverlap~sess+breedfem+sess:breedfem+(1|
> Site),family=poisson,data=Male)
>
> #test to see if sig difference between glm and glmm
> as.numeric(2*(logLik(mixed)-logLik(ma)))
> #99.16136
> pchisq(99.16136,1,lower=FALSE)
> #2.327441e-23 so should use a GLMM
>
The problem may be due to the random effects model containing an
interaction term sess:breedfem that the glm doesn't.
Ken
More information about the R-sig-mixed-models
mailing list