[R-sig-ME] Missing information in "name" column of Random effects output
Douglas Bates
bates at stat.wisc.edu
Wed Sep 26 15:10:16 CEST 2007
On 9/25/07, David Afshartous <dafshartous at med.miami.edu> wrote:
> Jorge,
> Awhile back I think I noticed a similar issue. I don't recall if I was able
> to do anything different w/ the lmer statement to fix it. In any event, my
> guess is that the first term corresponds to the intercept RE and the second
> to the slope RE. Looking at the estimated RE's themselves supports this:
Jorge is correct that the name column is no longer being filled out
and David is correct that the order of variance components corresponds
to the order of the terms in the model matrix for the random effects
term. Thanks to both of you for the report.
At some point I changed where the names are stored and I forgot to
update the VarCorr method accordingly. I will release a new version
with this fixed.
> > ranef(fm1)
> An object of class ³ranef.lmer²
> [[1]]
> (Intercept) Days
> 308 2.2713451 9.1966961
> 309 -40.3825921 -8.6223099
> 310 -38.9403378 -5.4521894
> 330 23.6656443 -4.8100611
> 331 22.2391295 -3.0662861
> 332 9.0324969 -0.2709760
> 333 16.8277808 -0.2214775
> 334 -7.2256113 1.0733822
> 335 -0.3503176 -10.7492136
> 337 34.8784025 8.6302064
> 349 -25.1898574 1.1699674
> 350 -13.0500361 6.6107496
> 351 4.5697621 -3.0138529
> 352 20.8539011 3.5376139
> 369 3.2744289 0.8723798
> 370 -25.5865985 4.8179542
> 371 0.8049003 -0.9877807
> 372 12.3075594 1.2851975
> > fm1.junk = ranef(fm1)[[1]]
> > int.ranef = fm1.junk[,1]
> > slope.ranef = fm1.junk[,2]
> > var(int.ranef)
> [1] 465.8012
> > var(slope.ranef)
> [1] 29.75055
> On 9/25/07 2:42 PM, "Jorge González" <jorge.gonzalez at psy.kuleuven.be> wrote:
>
> > Dear all,
> >
> > My apologies if this has been discussed before. When estimating a model
> > with lmer, I can't see anymore the contents of the "name" column in the
> > Random effects part of the output. See the example below
> >
> > ###### begin example ###################
> >> sessionInfo()
> > R version 2.5.1 (2007-06-27)
> > i386-pc-mingw32
> >
> > locale:
> > LC_COLLATE=Dutch_Belgium.1252;LC_CTYPE=Dutch_Belgium.1252;LC_MONETARY=Dutch_Be
> > lgium.1252;LC_NUMERIC=C;LC_TIME=Dutch_Belgium.1252
> >
> > attached base packages:
> > [1] "stats" "graphics" "grDevices" "utils" "datasets"
> > "methods" "base"
> >
> > other attached packages:
> > lme4 Matrix lattice
> > "0.99875-7" "0.999375-2" "0.16-5"
> >> fm1 <- lmer(Reaction ~ Days + (Days|Subject), sleepstudy)
> >> fm1
> > Linear mixed-effects model fit by REML
> > Formula: Reaction ~ Days + (Days | Subject)
> > Data: sleepstudy
> > AIC BIC logLik MLdeviance REMLdeviance
> > 1754 1770 -871.8 1752 1744
> > Random effects:
> > Groups Name Variance Std.Dev. Corr
> > Subject 610.835 24.7151
> > 35.056 5.9208 0.067
> > Residual 655.066 25.5943
> > number of obs: 180, groups: Subject, 18
> >
> > Fixed effects:
> > Estimate Std. Error t value
> > (Intercept) 251.405 6.820 36.86
> > Days 10.467 1.546 6.77
> >
> > Correlation of Fixed Effects:
> > (Intr)
> > Days -0.137
> >>
> > #################### end example ##################
> > How can I know which variance correspond to the subject random
> > intercept and which one to the subject slope Days? As far as I remember
> > this information was available in previous versions. Is this a bug?
> >
> > Thank you very much in advance
> >
> > Jorge
>
> _______________________________________________
> R-sig-mixed-models at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>
More information about the R-sig-mixed-models
mailing list