[R-sig-ME] how to extract the degrees of freedom in lmer

Douglas Bates bates at stat.wisc.edu
Thu Nov 20 20:01:05 CET 2008


On Thu, Nov 20, 2008 at 12:46 PM, Ben Bolker <bolker at ufl.edu> wrote:
>  This is really a special case of R FAQ 7.35,
>
> http://cran.r-project.org/doc/FAQ/R-FAQ.html#Why-are-p_002dvalues-not-displayed-when-using-lmer_0028_0029_003f
>
>  The very short answer is that Doug Bates, the author
> of lmer, no longer believes in the dominant paradigm of computing F
> statistics with a given numerator and a denominator df extracted by some
> approximation (preferably one which works correctly when applied
> to classical balanced orthogonal nested designs, where the
> paradigm is appropriate).  If you need to work in this paradigm
> you should probably continue to use lme ...
>
>  (and yes, that *was* "very short" compared to the discussion
> referenced in the above FAQ item ...)

You're not trying to indicate that I am somewhat wordy, are you, Ben?

> Anne Dubois wrote:
>> Dear all,
>>
>> Previously I was using "lme" and I could extract the denominator degrees
>> of freedom   with : summary(fit)$tTable[,3]
>>
>> Now, I am trying to do the same in "lmer" but I do not know if it is
>> possible because the degrees of freedom does not appear in the summary.
>> Can you help me, please ?
>>
>> Thank you for your time.
>> Sincerely,
>>
>> Anne Dubois (anne.dubois at inserm.fr)
>>
>> PS : To illustrate my problem, I use the dataset ergoStool (see below)
>>
>>
>>> Stool.lme<-lme(effort~Type,random=~1|Subject,data=ergoStool)
>>> summary(Stool.lme)
>> Linear mixed-effects model fit by REML
>> Data: ergoStool
>>       AIC      BIC   logLik
>>  133.1308 141.9252 -60.5654
>>
>> Random effects:
>> Formula: ~1 | Subject
>>        (Intercept) Residual
>> StdDev:    1.332465 1.100295
>>
>> Fixed effects: effort ~ Type
>>               Value Std.Error DF   t-value p-value
>> (Intercept) 8.555556 0.5760123 24 14.853079  0.0000
>> TypeT2      3.888889 0.5186838 24  7.497610  0.0000
>> TypeT3      2.222222 0.5186838 24  4.284348  0.0003
>> TypeT4      0.666667 0.5186838 24  1.285304  0.2110
>> Correlation:
>>       (Intr) TypeT2 TypeT3
>> TypeT2 -0.45              TypeT3 -0.45   0.50       TypeT4 -0.45
>> 0.50   0.50
>>
>> Standardized Within-Group Residuals:
>>        Min          Q1         Med          Q3         Max
>> -1.80200345 -0.64316591  0.05783115  0.70099706  1.63142054
>>
>> Number of Observations: 36
>> Number of Groups: 9
>>> summary(Stool.lme)$tTable[,3]
>> (Intercept)      TypeT2      TypeT3      TypeT4
>>         24          24          24          24
>>
>>
>>
>>> Stool.lmer<-lmer(effort~Type+(1|Subject),data=ergoStool)
>>> summary(Stool.lmer)
>> Linear mixed model fit by REML
>> Formula: effort ~ Type + (1 | Subject)
>>   Data: ergoStool
>>   AIC   BIC logLik deviance REMLdev
>> 133.1 142.6 -60.57    122.1   121.1
>> Random effects:
>> Groups   Name        Variance Std.Dev.
>> Subject  (Intercept) 1.7753   1.3324 Residual             1.2107
>> 1.1003 Number of obs: 36, groups: Subject, 9
>>
>> Fixed effects:
>>            Estimate Std. Error t value
>> (Intercept)   8.5556     0.5760  14.853
>> TypeT2        3.8889     0.5187   7.498
>> TypeT3        2.2222     0.5187   4.284
>> TypeT4        0.6667     0.5187   1.285
>>
>> Correlation of Fixed Effects:
>>       (Intr) TypeT2 TypeT3
>> TypeT2 -0.450             TypeT3 -0.450  0.500      TypeT4 -0.450
>> 0.500  0.500
>>
>>
>>
>
> _______________________________________________
> 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