[R-sig-ME] Understanding variance components

Henrik Singmann singmann at psychologie.uzh.ch
Fri Jan 13 18:06:59 CET 2017

Hi Gang,

Sorry that I so am late to the party, but in case you are still 
interested I will reply (and, of course, for the archive).

The answer is basically given in the old faq:

(1|site/block) = (1|site)+(1|site:block)

Which is exactly what is given in your output. A random intercept for 
Worker and a random intercept for each worker:Machine interaction.

To answer your questions. The random intercepts do not have base or 
reference levels. They are increments or decrements to the overall 
intercept for each level of Worker or the Machine:Worker combination. 
The reported variance is the estimated variance of these increments, 
which is most likely unequal to the actual variance you would obtain by 
calculating it from the estimated increments, which are sometimes called 
BLUPs (I wonder if a better term for those exist).

Hope that helps,

PS: Belated Happy New Year to everyone.

Am 05.01.2017 um 17:28 schrieb Chen, Gang (NIH/NIMH) [C]:
> Suppose that I have the following dataset in R:
> library(lme4)
> data(Machines,package="nlme")
> mydata <- Machines[Machines$Machine!='C’,]
> With the following model:
> print(lmer(score ~ 1 + (1|Worker/Machine), data=mydata), ranef.comp="Var")
> I have the variance components as shown below:
> Random effects:
>  Groups         Name        Variance
>  Machine:Worker (Intercept) 46.00
>  Worker         (Intercept) 13.84
>  Residual                    1.16
> I have trouble understanding exactly what the first two components are: Machine:Worker and Worker? Specifically,
> 1) What is the variance for Worker: corresponding to the base (or reference) level of the factor Machine? If so, what is the base level: the first level in the dataset or alphabetically the first level (it happens to be the same in this particular dataset)?
> 2) What is the variance for Machine:Worker? Is it the variance for the second level of the factor Machine, or the extra variance relative to the variance for Worker?
> Furthermore, for the model:
> print(lmer(score ~ 1 + (1|Worker/Machine), data=Machines), ranef.comp="Var")
> what is the variance for Machine:Worker in the following result since there are 3 levels involved in the factor Machine?
> Random effects:
>  Groups         Name        Variance
>  Machine:Worker (Intercept) 60.2972
>  Worker         (Intercept)  7.3959
>  Residual                    0.9246
> Thanks,
> Gang
> _______________________________________________
> 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