Statalist


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

st: Re: ztnb and residuals


From   "Martin Weiss" <martin.weiss1@gmx.de>
To   <statalist@hsphsun2.harvard.edu>
Subject   st: Re: ztnb and residuals
Date   Sat, 28 Mar 2009 21:27:52 +0100

<>


It is quite easy to replicate the model w/o trunctation as a glm - which gives you access to more residuals in -predict-:

*****
webuse rod93, clear
tab cohort, gen(coh)
generate logexp=ln(exposure)
nbreg deaths coh2 coh3, exposure(exp)
glm deaths coh2 coh3, family(nbinomial) link(log) exposure(exposure)
predict dev, deviance
predict pea, pearson
*****

Maybe other listers know how to incorporate the truncation part into this story

HTH
Martin
_______________________
----- Original Message ----- From: Megan McKeown
To: statalist@hsphsun2.harvard.edu
Sent: Saturday, March 28, 2009 3:20 PM
Subject: st: ztnb and residuals


Hello Statalist,
I am using a zero-truncated negative binomial regression to model count data. Does anyone have any suggestions as to how I could obtain Standarized Pearson Residuals and/or Deviance Residuals for this model? I have explored simple postestimation commands.
Thanks for your time!
Megan
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index