Short summary of the problem
brm.formula.1 <- bf(
y ~ 0 + group+
# Group-specific independent random intercepts
(1 | gr(ID, by = group)),
sigma ~ 0 + group
)
prior_1 <-
# coefficients
prior(normal(log(250), 50), class = "b", coef = "groupA") +
prior(normal(log(250), 50), class = "b", coef = "groupB") +
# intercepts
prior(student_t(3, 0, 1), class = "sd", group = "ID:groupA", coef = "Intercept") +
prior(student_t(3, 0, 1), class = "sd", group = "ID:groupB", coef = "Intercept") +
# sigma
prior(student_t(3, 0, 2), class = "b", dpar = "sigma", coef = "groupA") +
prior(student_t(3, 0, 2), class = "b", dpar = "sigma", coef = "groupB")
The above code doesnt work for me. brms tells me that it couldnt find the names for the random intercept priors.
When using get_prior(), only a single prior is shown for the random-intercept distribution.
Following this I checked the the priors using prior_summary and it seems like only one sd intercept prior is can be set and this is applied to each group of by = group.
Is this the correct understanding @paul.buerkner