Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: st: Poisson and Negbin models

From   Simon Falck <>
To   "" <>
Subject   RE: st: Poisson and Negbin models
Date   Mon, 29 Oct 2012 10:02:33 +0000

Thanks Maarten.

I have only used the tests to explore the distribution of the data, and see your point of them not being relevant. 

I have downloaded your "berlin12 example" on comparing distributions. Strangely, the -margdistfit- did not to work after any count model. I got this error message after -poisson-:

. margdistfit, hangroot(susp notheor jitter(2)) name(poisson)
margdistfit cannot be used after poisson

I tried the other models (non count), for which -margdistfit- worked well. 

Can you think of why I cannot use -margdistfit- after count models? Is it because I am using Stata v. 11.2, and would need Stata 12.x?


-----Original Message-----
From: [] On Behalf Of Maarten Buis
Sent: den 29 oktober 2012 10:17
Subject: Re: st: Poisson and Negbin models

> The first indication is it that Y is overdispersed as the mean and the variance is not equal, nor close being equal (mean 4.347222 < var 542.6806). A formal Goodness-of-fit test of Y alone, using estat gof- after -poisson $y-, indicates Y is significantly different from a Poisson distribution (chi2 = 1726.882, Prob > chi2(71) = 0.0000). Similarly the LR test of alpha related to the output from -nbreg $y- indicates that the negbin model is preferred over the Poisson (LR=0:  chibar2(01) = 1570.16 Prob>=chibar2 = 0.000).

Those are not appropriate tests as you would not expect the marginal distribution of y to Poisson or negative binomially distribution, otherwise you would not have added the explanatory variables later on... See e.g. <>

> When I run the model Y=X1 X2...Xn, using the -nbreg- command, I end up with some problems. The model outcome indicates some problem with the alpha, and a LR test indicating that the Poission is preferred over the negbin model:
> -------------+--------------------------------------------------------
> -------------+--------
>     /lnalpha |  -18.90698   558.4214       113.393    1075.579
> -------------+--------------------------------------------------------
> -------------+--------
>        alpha |   6.15e-09   3.43e-06                             0           .
> ----------------------------------------------------------------------
> -------- I would appreciate if someone could explain what seems to be 
> the problem(s) here, and some indication on the problem related to the alpha in the negbin model.

A Poisson model is a negative binomial model with an alpha of 0. In your case the alpha is 0.000000000615 (if I counted the 0s correctly).
So to all intends and purposes you estimated a Poisson model with -nbreg-.

-- Maarten

Maarten L. Buis
Reichpietschufer 50
10785 Berlin

*   For searches and help try:

*   For searches and help try:

© Copyright 1996–2017 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index