Open XiangShawnZhang opened 10 months ago
Thank you @XiangShawnZhang for trying out the package and for spotting the bug! I was able to replicate the bug, and I think the issue is that outreg2
and esttab
look for estimates stored in e(b)
and e(V)
, which are default Stata matrices for regression estimates and standard errors. However, for reasons explained under saved output
section of the help file, eventstudyinteract
has to store the regression output in e(b_iw)
and e(V_iw)
instead. I just updated the help file with a workaround, which overwrites the default e(b)
and e(V)
with the output from eventstudyinteract
. Could you please try the following to see if it resolves the bug?
matrix b = e(b_iw)
matrix V = e(V_iw)
ereturn post b V
esttab
Can we export more than one regression results at one time?
I suspect you can trick eststo similarly:
eventstudyinteract model1
matrix b = e(b_iw)
matrix V = e(V_iw)
ereturn post b V
eststo model1
eventstudyinteract model2
matrix b = e(b_iw)
matrix V = e(V_iw)
ereturn post b V
eststo model2
esttab
Hope this helps!
Your answer helps a lot!
Hi Liyang,
Thanks for your great work on the package! I have a naive question on how to better export the regression results of eventstudyinteract. I met the issue of the variable names of the time period when I tried to export the results with "outreg2" or "esttab". I appreciate your suggestion on that.
Thanks!