I’m fitting a sequential ordinal model (family = sratio
) and would like to set up a random-effects variance-covariance matrix for each level of a grouping factor AND to include category-specific effects as random slopes.
This works:
bf(Response ~ 1 + cs(Group * Condition) +
(1 + Condition | gr(Participant_ID, by = Group))
This also works:
bf(Response ~ 1 + cs(Group * Condition) +
(1 + cs(Condition) | Participant)
But this doesn’t:
bf(Response ~ 1 + cs(Group * Condition) +
(1 + cs(Condition) | gr(Participant_ID, by = Group))
I get the following error message:
Error in frame_re(x, data = data, old_levels = old_levels) :
rsub$type[i] %in% c("", "mmc") is not TRUE
Is such a model possible in brms?
- Operating System: Linux
- brms Version: 2.22