I am in the midst of running "control function approach" where in the first stage I am using xtlogit command (endogenous variable is binary) and xtreg command (outcome variable is continuous) in the second stage to deal with endogeneity. I need to obtain predicted "generalised residuals" after running first stage regression and use that as an additional variable in the second stage. I have not yet been able to figure out a way to do it in Stata. Looking for directions from this group on how I can achieve this using Stata code. Thanks.
-
Login or Register
- Log in with
Comment