I have an unbalanced dataset of 8,000 observations for 2,000 IDs:
xtset id year
panel variable: id (unbalanced)
time variable: year, 2006 to 2017, but with gaps
delta: 1 unit
I have a policy changed that occurred in 2014. I created the time and the ID effects and ran the following Difference in Difference to calculate the effect on takeup:
xtreg takeup i.treated##i.post14
Is this the right code, or should add at the end:RE, FE, R, or other options?
Thanks,
xtset id year
panel variable: id (unbalanced)
time variable: year, 2006 to 2017, but with gaps
delta: 1 unit
I have a policy changed that occurred in 2014. I created the time and the ID effects and ran the following Difference in Difference to calculate the effect on takeup:
xtreg takeup i.treated##i.post14
Is this the right code, or should add at the end:RE, FE, R, or other options?
Thanks,
Comment