Brms prior speficiation in negative binomial model

I’m using brms for regression analysis assuming negative binomial model,
but I get " E-BFMI less than .2" error.
I read somewhere else that this error might be avoided by specifying appropriate priors,
but not sure how to improve my prior.

If there is any suggestion, please let meknow.

bprior ← c(prior(uniform(-1, 1), class=ar),

prior(cauchy(0, 1), class=sderr),

prior(normal(0,10), class = b),

prior(normal(0,10), class = Intercept),

prior(cauchy(0, 1), class=shape)

)

It’s difficult to comment on your priors without knowing more about your data and your model. But at a superficial glance, your intercept prior is pretty vague. Try something more like prior(normal(log(x), 1), class = Intercept), where the value of x is where you’d expect the mean of your data to be when all the predictors are at zero. Also, unless your predictors have extreme scales, I’d also reign in your class = b prior to something more like prior(normal(0, 1), class = b).

Thank you very much, seems like problem solved about the e-bfmi issue following your advice.
Still got issue with discrepancy between waic and loo(and loo’s pareto_k > 0.7 warnings), but I’ll create another thread for this issue if I cannot find any solution.

By the way, I’m modelling generalized linear model-like regression , with count data as response variable and several other explanatory variables, with autocorrelated errors.

1 Like