Hello all,
I’m working with some survey results where we have summarized proportions of responses to a particular item (essentially: for, neutral, and against), and a set of causally implicated predictors. I’ve taken the approach below to model the proportions as separate multivariate outcomes of the same set of predictors using beta regressions, but I assume brms (and, by extension, Stan) could do a better job if it knew the three proportions together form a simplex. Is there a way to specify this in brms? If not, what would the structure of the Stan model need to look like?
There are additional complexities, shown in the code below, in that the responses and some predictors have measurement error, and have a hierarchical structure. The goal is to then use the fitted model for prediction, given new inputs.
modelA = bf(PropA | mi(PropA_se) ~
mi(predictorone) + mi(predictortwo) + predictorthree +
(1 + mi(predictorone) + mi(predictortwo) + predictorthree | stratum),
family=Beta()) +
bf(predictorone | mi(predictorone_se) ~ 1, family=gaussian()) +
bf(predictortwo | mi(predictortwo_se) ~ 1, family=gaussian())
modelB = bf(PropB | mi(PropB_se) ~
mi(predictorone) + mi(predictortwo) + predictorthree +
(1 + mi(predictorone) + mi(predictortwo) + predictorthree | stratum),
family=Beta())
modelC = bf(PropC | mi(PropC_se) ~
mi(predictorone) + mi(predictortwo) + predictorthree +
(1 + mi(predictorone) + mi(predictortwo) + predictorthree | stratum),
family=Beta())
multiFit = brm(mvbf(modelA, modelB, modelC, rescor=F),
data=data,
prior=c(prior(normal(0,1), class="b")),
init="0",
warmup=5000, iter=15000,
cores=parallel::detectCores(), chains=4,
control=list(adapt_delta=0.95, max_treedepth=15),
backend="cmdstanr",
seed=seed)
I appreciate any help or speculation on solutions. Thank you!