Hi there,
I’m quite new to brms and especially to handling the beta distribution, so I hope my issue is not too low-level:
I want to fit a Bayesian model with a response variable distributed between 0 and 1 (with zero inflation), so I decided for the zero inflated beta family in brms.
fit <- brm(formula = y ~ 1,
data = data,
family = zero_inflated_beta(link = "logit", link_phi = "log", link_zi = "logit"))
But along the way, some unclarities have emerged:
-
When learning more about the beta distribution, it turned out that there seem to be two different ways for its parameterization: (a) mu/mean and phi/precision parameter, or (b) a and b with a = mu*phi and b = (1−mu)*phi. I’m not entirely sure which parameterization is used in brms.
-
I’m struggling with interpreting the posteriors because of the logit/log transformation in the beta model. Do I understand it correctly: The posterior estimates for “Intercept”/“phi” are in logit/log scale, hence need to be converted into probability scale for interpretation?
estimate.Intercept <- posterior_summary(as.data.frame(fit)$b_Intercept)[1] a <- exp(estimate.Intercept) / (1 + exp(estimate.Intercept) ) estimate.phi <- posterior_summary(as.data.frame(fit)$phi)[1] #phi b <- exp(estimate.phi)
And when transformed, those two are the parameters needed to define the shape of the beta distribution? So, basically dbeta(x, a, b) returns the curve of my predicitve posterior distribution?
Thanks a lot!