Dear Stata Forum Users,
I am running multiple linear regressions some without and some with controls. For the latter I have calculated the delta value using Oster's (2019) psacalc command. I would like to add these estimates to my final regression tables, however, something in my code appears to be not working. If I run a single regression (e.g. Model 2 here) and export my results using outreg2 this works perfectly fine (https://www.statalist.org/forums/for...ound-estimates). However, once I add other models Stata appears to not find the stored delta values anymore (Error message: check eret list for the existence of e(delta1))
I hope my code is comprehensive and look forward to any hints on how to solve this issue! Thank you!
I am running multiple linear regressions some without and some with controls. For the latter I have calculated the delta value using Oster's (2019) psacalc command. I would like to add these estimates to my final regression tables, however, something in my code appears to be not working. If I run a single regression (e.g. Model 2 here) and export my results using outreg2 this works perfectly fine (https://www.statalist.org/forums/for...ound-estimates). However, once I add other models Stata appears to not find the stored delta values anymore (Error message: check eret list for the existence of e(delta1))
Code:
reg gr3_math std, robust
est store m1
reg gr3_math std $controls, robust
est store m2
psacalc delta `std'
scalar delta1 = r(delta)
estimates restore m1
estadd scalar delta1
reg gr3_lang std, robust
est store m3
reg gr3_lang std $controls, robust
est store m4
psacalc delta `std'
scalar delta1 = r(delta)
estimates restore m1
estadd scalar delta1
outreg2 [m1 m2 m3 m4] ///
using "$tables/Trial", ///
excel dec(3) label replace ///
keep(std) addstat(Oster's (2012) Delta, e(delta1))

Comment