When I use lmer
of lme4
to fit a random one-variable slope model with random intercept excluded, both levels of the one-variable slope are reported with random variances, as if the slope had two variables (i.e., as if it were a three-level treatment effect). How should I interpret this?
Detailed Example:
Scenario 1
Here is what the model looks like with both random slope and intercept included. Everything works as expected: in line 7, the binary variable Cond1
shows up with just one effect (Cond1hetero
, the upper level of the two-level categorical)...
> RT_log.CVquestA.lmer=lmer(RT_log~Cond1+(1+Cond1|Subject),data=basedata)
> summary(RT_log.CVquestA.lmer)
...
Random effects:
Groups Name Variance Std.Dev. Corr
Subject (Intercept) 0.026121 0.16162
Cond1hetero 0.001366 0.03696 -0.47
Residual 0.028667 0.16931
Number of obs: 3321, groups: Subject, 19
Fixed effects:
Estimate Std. Error t value
(Intercept) 6.57461 0.03725 176.49
Cond1hetero 0.02815 0.01052 2.68
Correlation of Fixed Effects:
(Intr)
Cond1hetero -0.412
Scenario 2
Here is what the model looks like when I remove the random intercept. Note the extra variance term on line 6 of the block below (i.e., we now see an effect for Cond1non-hetero
, the reference level of the Cond1
categorical variable, in addition to the upper level Cond1hetero
). I don't know how to interpret or use this output!
> RT_log.CVquestB.lmer=lmer(RT_log~Cond1+(0+Cond1|Subject),data=basedata)
> summary(RT_log.CVquestB.lmer)
...
Random effects:
Groups Name Variance Std.Dev. Corr
Subject Cond1non-hetero 0.02612 0.1616
Cond1hetero 0.02184 0.1478 0.98
Residual 0.02867 0.1693
Number of obs: 3321, groups: Subject, 19
Fixed effects:
Estimate Std. Error t value
(Intercept) 6.57461 0.03725 176.49
Cond1hetero 0.02815 0.01052 2.68
Correlation of Fixed Effects:
(Intr)
Cond1hetero -0.412
Cond1
and both are shown in the output, as they should. Nothing extra seems to be present. Why don't you simplify the situation and run the simplest possible regression that involves this variable, something likelm(RT_log ~ 0+Cond1)
. Does its output make sense or not? $\endgroup$ – whuber♦ Feb 29 '16 at 15:14lm
is an appropriate model, but only to help you see where your misunderstanding lies. I warmly recommend actually running that command and looking at its output. This is not a problem with mixed effects, but with understanding how regression works and how to code categorical variables. $\endgroup$ – whuber♦ Feb 29 '16 at 15:21Cond1hetero
means two different things in the two scenarios. In the first, it represents the difference between that level and the base level; in the second, it represents the actual value of that level, rather than a difference. Note the very different correlation coefficients reported in the right-handCorr
column. $\endgroup$ – whuber♦ Feb 29 '16 at 15:52