I have a question about diff-in-diff results with different commands.
x1 is the time-variant binary variable, if it is before the treatment it's 0, if its after the treatment its 1.
The first two diff-in-diff regression commands give me exactly same results in terms of ATET and i.x1#i.x2.
However, with xtreg, "i.x1" is not omitted, and this sounds a little awkward, since I have controlled for the time-fixed effect in the first command.
When I run the same diff-in-diff with reghdfe, only the interaction term is left, and non-interacted terms are omitted as expected.
So my question is, why is command using
returning some value for i.x1? (which is totally unexpected, considering its original value when estimated solely e.g. xtreg i.x1, fe robust)
Thank you.
x1 is the time-variant binary variable, if it is before the treatment it's 0, if its after the treatment its 1.
Code:
1. xtreg y i.x1##i.x2 i.date, fe robust gen treat = (x1 == 1 & x2 == 1) 2. xtdidreg (y) (treat), group(id) time(date) 3. reghdfe y i.x1##i.x2, absorb(id date) vce(robust)
The first two diff-in-diff regression commands give me exactly same results in terms of ATET and i.x1#i.x2.
However, with xtreg, "i.x1" is not omitted, and this sounds a little awkward, since I have controlled for the time-fixed effect in the first command.
When I run the same diff-in-diff with reghdfe, only the interaction term is left, and non-interacted terms are omitted as expected.
So my question is, why is command using
Code:
xtreg y i.x1##i.x2 i.date, fe robust
Thank you.
Comment