Bookmark and Share

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


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

st: Generalized residuals after ordered probit estimation


From   [email protected]
To   [email protected]
Subject   st: Generalized residuals after ordered probit estimation
Date   Sat, 22 Oct 2011 19:42:33 +0200 (CEST)

Dear Stata-Listers,


I have some problems in calculating the generalized residuals after the
estimation of an ordered probit model.
For y = [0,1,2] it should be something like this:

predict `xb_hat', xb
gen r = 0
replace r = (-normalden(_b[/cut1] - xb_hat))/(normal(_b[/cut1] - xb_hat)) 
if (y == 0)
replace r = (normalden(_b[/cut1] - xb_hat) - normalden(_b[/cut2] -
xb_hat))/(normal(_b[/cut2] - xb_hat)-normal(_b[/cut1] - xb_hat))  if (y ==
1)
replace r = normalden(_b[/cut2] - xb_hat)/(1 - normal(_b[/cut2] - xb_hat))
 if (y == 2)

Unfortunately, the sum of my residuals is never even close to zero. Do you
have any advice?
Perhaps I didn't really understood Stata's parameterization of the
constant/cutpoints?

Thanks,
Sven
*
*   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–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index