Can you use two crossed random effects when you have many levels (50+) of both? This mixed effects model is fitting atrophy in many brain regions (n=242) in a set of subjects (n=71). I have two predictors, pathlength and hazard. These vary across region, in a way that is different for each subject. I am including crossed random intercepts for region and subject.

lme_atrophy <- lmer(atrophy ~ pathlength + hazard + (1|region) + (1|subject), data = regions)

When I fit the model, pathlength and hazard are both significant predictors:

Random effects:
 Groups   Name        Variance Std.Dev.
 region   (Intercept) 0.003332 0.05772 
 subject  (Intercept) 0.006103 0.07812 
 Residual             0.014649 0.12103 
Number of obs: 36784, groups:  region, 242; subject, 71

Fixed effects:
             Estimate Std. Error t value
(Intercept)  0.115157   0.010778  10.684
pathlength  -0.025014   0.001716 -14.574
hazard      -0.010363   0.002739  -3.784

The purpose of the model is to predict atrophy for a given subject in all 242 regions, and for the predictions to be diverse for different subjects. The problem is that the 242x1 fitted values of atrophy for different subjects end up being very highly correlated with each other - it's basically fitting the mean spatial pattern. The random intercept for region seems to dominate the estimates:

    Class   Family     Link     n    Marginal Conditional  
1 lmerMod gaussian identity 36784 0.009429902   0.3974807  

My questions are:

  1. Would using a nested random intercept for region within subject make more sense? I don't care to interpret the region effects. Each individual brain is a unique spatial entity, but a given region does have some population-level consistency.
  2. If I try an alternative random effect for region, like using a random slope of pathlength for each region without an intercept (a possibility offered in Keep it maximal), am I ignoring the repeated-measures-in-space structure of my data to my peril (eg too much type 1 error)?
  3. Are the predictors just not powerful enough, and so the model settles on just predicting the mean pattern for each subject?
  • $\begingroup$ How many unique values of path length are there? 72, 242, or 36784? Same q for hazard? Those re are not crossed btw, so region is the mean spatial pattern for your population. Or alternatively the consistency of a region across subjects. $\endgroup$
    – atiretoo
    Feb 8, 2018 at 12:32
  • $\begingroup$ 36784 unique values of pathlength and hazard. What makes you say they're not crossed? I thought this was the correct way to cross random intercepts (like here). I guess the question becomes, am I justified in not modeling the mean spatial pattern? $\endgroup$
    – jbrown
    Feb 8, 2018 at 19:46
  • $\begingroup$ thank you for the clarification -- i don't use crossed for that situation. $\endgroup$
    – atiretoo
    Feb 8, 2018 at 23:35

1 Answer 1


The BLUPS estimated for each region will represent the deviation of atrophy of that region from the average region. That departure will be the same for all subjects, so it makes sense to describe it as the "mean spatial pattern" for the population. The estimated variance is not small, so there are consistent differences between regions across all subjects. The deviation for region 1 is the same in subject a and subject b.

1) Changing to a nested random effect is assuming that the random deviation of region 1 in subject a is different from region 1 in subject b. Whether that's a better way to model it or not is a theoretical question more than a statistical one. Actually, I'm not sure a nested design makes sense or is estimable because you only have one observation per subject-region.

2) That's a nice reference! However, the "random slopes with no intercept" model they suggest is given as a possibility, not necessarily a good idea. Random slopes without random intercepts look, well, weird. A whole bunch of lines with different slopes that all go through the same point. Doesn't mean it couldn't happen, but think carefully about whether that would ever make sense. I think a more reasonable "maximal model" would be

atrophy ~ pathlength + hazard + (1+pathlength|region) + (1+pathlength|subject)

But either way, I think you're accounting for any within class correlations caused by spatial consistency or within subject.

3) No. Despite accounting for the mean spatial pattern there is still a significant signal of pathlength and hazard.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.