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

st: Re: ztnb and residuals

From   "Martin Weiss" <>
To   <>
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

----- Original Message ----- From: Megan McKeown
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!
*   For searches and help try:

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