Hi folks,

I’m trying to fit a multivariate model to some data - the same participants, three different tasks, a few shared predictors. The data for the model is here multivar_dat.csv (223.5 KB)

, and the code is below - also I’m using brms 2.15.9.

```
bf_blicks <- bf(PreferAntepenult|subset(Blicks == TRUE) ~ (1|a|Subject)+(1|Item))+bernoulli()
bf_trisyllabic_local <- bf(DerivativeStressTrisyll|subset(DerivativesTrisyll == TRUE) ~
scale(LocalBaseFreq)+
StressProfile+
TypeOfRemoteBase+
(1+
scale(LocalBaseFreq)+
StressProfile+
TypeOfRemoteBase|a|Subject)+
(1|Item)
)+categorical()
bf_disyllabic_local <- bf(DerivativeStressDisyll|subset(DerivativesDisyll == TRUE) ~
scale(LocalBaseFreq)+
TypeOfRemoteBase+
StressProfile+
(1+
scale(LocalBaseFreq)+
TypeOfRemoteBase+
StressProfile
|a|Subject)+
(1|Item))+bernoulli()
job({multivar_model<- brm(
formula = bf_blicks+bf_trisyllabic_local+bf_disyllabic_local,
data = multivar_dat,
chains = 4,
cores = 4,
warmup = 1000,
iter = 2000,
file = "./Models/a_first_multivariate_model",
save_all_pars = T,
save_model = './Models/a_first_multivariate_model_stan'
)})
```

I’m running into the error

```
Error in new_CppObject_xp(fields$.module, fields$.pointer, ...) :
Exception: variable does not exist; processing stage=data initialization; variable name=Z_2_mu2_DerivativeStressTrisyll_7; base type=double (in 'string', line 50, column 2 to column 70)
failed to create the sampler; sampling not done
```

And I’m not sure what to do - the same thing happens when I run only two of the models together at a time. Any suggestions on how to proceed? Also, I’m not sure if this is a brms-level error or a stan-level error, so please let me know if I’m posting this in the wrong place.

Sincerely,

Canaan