Open wangxinge opened 4 years ago
Negative Binomial regression is not natively supported yet, but I will make it a priority adding it. Specifically:
mcp(..., family = negbinomial())
with appropriate default priors.model = list(y ~ 1 + x + shape(1 + x), data = df)
which_y = "shape"
in plot()
, fitted()
, etc.Until then, should be able to "hack" it by looking at the JAGS code in fit$jags_code
for a regular binomial model and replace dbin(y_[i_], N[i_])
with dnegbin(y_[i_], shape)
and add an appropriate prior, e.g., for shape ~ dunif(0, 50)
. Then feed that string into mcp
again via mcp(model, data, jags_code = your_updated_code)
. This won't return posterior samples for shape
, unfortunately.
Hi there, Can I use glm.nb for the regression? Thank you!