Aesler
Aesler

Reputation: 181

Fitdistrplus unsupported distribution error

I am trying to verify whether my data set fits exponential or negative binomial, the function works for exponential but I get the following error using "nbinom":

> compare = fitdistr(A, densfun="nbinom") 

Error in fitdistr(A, densfun = "nbinom") : unsupported distribution

Note: I know I need more than this to verify its likely distribution. But the issue I am having is more the fact the "nbinom" isn't functioning

Upvotes: 0

Views: 1327

Answers (1)

Julia Wilkerson
Julia Wilkerson

Reputation: 581

It looks like you're conflating the function you've used, MASS::fitdistr(), with fitdistrplus::fitdist().

From the documentation, you can see "negative binomial" is the character string specifying this distribution in the fitdistr function you've used.

Upvotes: 2

Related Questions