I am using brms 2.18.0 and get an error message when estimating a model with a random effect.
This is the model code:
M1 <- brm(
fluency ~ 1 + Occ2*FL + Occ2*MT + Occ3*FL + Occ3*MT + (1|student) ,
data = Subtitles,
cores = 4,
backend = "cmdstanr",
seed = 1975,
prior = Custom_prior1
)
This generates the following error:
Syntax error in '/var/folders/x9/dk2f_b5575ddx5s7sscrgtch0000gn/T/RtmpkeCz4K/model_ca7319f434761380a27341051b9df070.stan', line 12, column 18 to column 19, parsing error:
-------------------------------------------------
10: int<lower=1> N_1; // number of grouping levels
11: int<lower=1> M_1; // number of coefficients per level
12: int<lower=1> J_1[N]; // grouping indicator per observation
^
13: // group-level predictor values
14: vector[N] Z_1_1;
-------------------------------------------------
";" expected after variable declaration.
Error: Syntax error found! See the message above for more information.
When leaving out the +(1|student)
in the model, the model compiles and gets estimated.
I have no clue what’s happening. But could it be due to the fact that I updated my laptop to macOS Sonoma (v. 14.3)?
Thanks for your help