[R-sig-ME] Always allow for correlation of random effects?

Ben Bolker bbolker at gmail.com
Wed Dec 4 01:59:21 CET 2013


Reinhold Kliegl <reinhold.kliegl at ...> writes:

> 
> Does the following relate to the issue you are discussing here?
> 
> # If a and b are intercept and slope, then the
> # offset for X to obtain a zero intercept-slope
> # correlation parameter is cov(a,b)/var(b).
> # (I saw this derivation, which also yields a minimum
> # variance estimate for the intercept, in a 2007 GLMM
> # handout by Ulrich  Halekoh.)
> 
> # An illustration with the sleepstudy data.
> library(lme4)
> summary(fm1 <- lmer(Reaction ~ Days + (Days|Subject), sleepstudy))
> VarCorr(fm1)
> 
> ## Groups   Name        Std.Dev. Corr
> ## Subject  (Intercept) 24.7406
> ##          Days         5.9221  0.066
> ## Residual             25.5918
> 
> # Compute the offset and add it to Days
> # (i.e., a very specific, but linear transformation of Days)
> sleepstudy$DaysA <- sleepstudy$Days + (0.066*24.7405*5.9221)/35.072
> summary(fm3 <- lmer(Reaction ~ DaysA + (DaysA|Subject), sleepstudy))
> 
> VarCorr(fm3)
> ##Groups   Name        Std.Dev. Corr
> ##Subject  (Intercept) 24.6874
> ##         DaysA        5.9221  0.000
> ##Residual             25.5918
> 
> Reinhold Kliegl

  Yes, that's a large part of it.  There may have been some other
aspects to the example, but I think this illustrates the main point.
My interpretation is that unless the zero point of the continuous
covariate has strong theoretical meaning, so that a location shift
doesn't make sense, the hypothesis (correlation=0) is 
dubious.  This seems analogous to the old rule that one shouldn't
compare between-group (intercept) differences in an ANCOVA model
(one with an interaction between a continuous and a categorical 
predictor), because they can be made to match any arbitrary value
by shifting the location of the continuous predictor.



More information about the R-sig-mixed-models mailing list