Sunday, 8 September 2013

How do I designate a negative binomial error distribution in a GLM using R?

How do I designate a negative binomial error distribution in a GLM using R?

I'm constructing a model using the glm() function in R. Let's say that I
know that my data have an error distribution that fits a negative binomial
distribution.
When I search the R manual for the various families, family=binomial is
offered as an option, but negative binomial is not.
In the same section of the R manual (family), NegBinomial is linked in the
"See also" section, but it is presented in the context of binomial
coefficients (and I'm not even sure what this is referring to).
So, to summarize, I'm hoping to find syntax that would be analogous to
glm(y~x, family=negbinomial, data=d,na.omit).

No comments:

Post a Comment