[R-sig-ME] Do I need random effects?
Murray Jorgensen
maj at waikato.ac.nz
Fri Feb 25 04:07:19 CET 2011
I want to test if two random effects are needed. I rather hope that they
are not.
I believe the 0/1 response mincr [male increase] should depend on the
factor icfac [initial configuration] but not on two other factors gap
and comp, which would be crossed were it not for missing values.
> m1 = lmer(mincr ~ icfac + (1|gap) + (1|comp), REML = FALSE)
> summary(m1)
Linear mixed model fit by maximum likelihood
Formula: mincr ~ icfac + (1 | gap) + (1 | comp)
AIC BIC logLik deviance REMLdev
-259.8 -228.7 136.9 -273.8 -250.3
Random effects:
Groups Name Variance Std.Dev.
comp (Intercept) 0.000000 0.00000
gap (Intercept) 0.000000 0.00000
Residual 0.037834 0.19451
Number of obs: 627, groups: comp, 40; gap, 8
Fixed effects:
Estimate Std. Error t value
(Intercept) 1.261e-11 1.108e-02 0.000
icfacmale1 5.556e-01 2.331e-02 23.836
icfacfem1 -3.129e-11 1.715e-02 0.000
icfacother 2.500e-01 6.966e-02 3.589
Correlation of Fixed Effects:
(Intr) icfcm1 icfcf1
icfacmale1 -0.476
icfacfem1 -0.646 0.307
icfacother -0.159 0.076 0.103
Zero variance components are estimated for the gap and comp effects.
Goodie! But does this constitute a test? What if they were merely smallish?
Then I would like to do:
m0 = lmer(mincr ~ icfac)
anova(m0,m1)
But lmer won't let me fit models with no random effects.
Regards, Murray
--
Dr Murray Jorgensen http://www.stats.waikato.ac.nz/Staff/maj.html
Department of Statistics, University of Waikato, Hamilton, New Zealand
Email: maj at waikato.ac.nz majorgensen at ihug.co.nz Fax 7 838 4155
Phone +64 7 838 4773 wk Home +64 7 825 0441 Mobile 021 0200 8350
More information about the R-sig-mixed-models
mailing list