Sigmas for marginal contrasts in distributional model

Hello,

I am a bit puzzled by factorial (split plot) designs (3x7) and how to get correct sigmas for each marginal group and or condition. For the first model I assumed homogeneity, for the second (below) I estimated sigma by group*condition to allow heterogeneity and for the third (not shown) I additionally used a student t distribution. For simplicity I show the second model without t distribution, priors or other irrelevant information. All models showed convergence etc. and loo favored the third one.

mod.2 <- brm(family = gaussian,
              data = data,
              bf(DS ~ 0 + group*condition + (1|id_fb), 
                 sigma ~ 0 + group*condition),
              […]

For the second and third model, it was pretty straight forward to get the mu and sigmas for each of the 21 group x condition combinations, by adding the according posterior distributions for each b (deflection parameter). Now, I wanted to combine the according groups / conditions to get the “main effects”. For the mu values, it seemed plausible to take the mean of the group / condition posterior distributions, respectively. All the wrangling worked well and agree with the results of the emmeans package, for example.

But here the problem/question: I would like to calculate the marginal pairwise comparisons and want to report the effect size delta (e.g. Meredith & Kruschke, 2021), for which I need the sigmas of each marginal mean group, e.g. group1 marginalized over all conditions, to compare group1 vs group 2. Taking the mean (as for the mus) does not sound reasonable for me, as well as combining the distributions of the bs. I also modeled the sigma only with group or condition (below), which delivered reasonable results, but are separate models. So, is it possible to calculate the sigmas from the original model above?

mod.2.1 <- brm(family = gaussian,
              data = data,
              bf(DS ~ 0 + group*condition + (1|id_fb), 
                 sigma ~ 0 + group),
              […]
mod.2.2 <- brm(family = gaussian,
              data = data,
              bf(DS ~ 0 + group*condition + (1|id_fb), 
                 sigma ~ 0 + condition),
              […]

Do I miss something obvious or what do I oversee here?

Any help appreciated.
Best, Rainer
@paul.buerkner @Solomon

I think that’s something you’ll need to do manually with the output from as_draws_df().

Dear @Solomon , many thanks for taking your time.

This is exactly what I did, but the estimated sigmas for the marginal groups seem too small. For example, the mean sigmas averaged across conditions from the posterior from mod.2 above are:

sigma group_1 = 1.39
sigma group_2 = 1.44
sigma group_3 = 1.44

If I take the estimates from mod.2.1 above, where I directly modeled sigma by group, I get:

sigma group_1 = 1.89
sigma group_2 = 1.74
sigma group_3 = 1.77

which is in the very close to the descriptive statistics of the sample data (as expected in the gaussian model):

sd group_1 = 1.91
sd group_2 = 1.81
sd group_3 = 1.84

The esimates from mod.2 seem a bit too small and I asked myself if this is the correct way, to average the posterior sigmas across all conditions and if not, is it possible to get this information from mod.2, in the first place or do I need to model several models?