Dear all,
I have already read a lot of things about specifying a Diff-in-Diff model, but there is still something I didn't get. I want to estimate a Diff-in-Diff model where the treatment lasts over two time periods and I want to estimate the treatment effects for both periods. Therefore I have an idea how I should estimate the model (Model 1), but I also think about a similar model (Model 2), where I don't really get the point, if it is still a Diff-in-Diff model or not.
My variables are labelled as follows:
depvar: ordinal (0-4)
treat: 0 for control, 1 for treatment
ttime: 0 for the period before treament, 1 for the periods after treatment
period: 0-2
covariates
I estimated my models as follows after "xtset id period"
Model 0: meglm depvar i.treat##i.ttime covariates, family(ordinal) link(logit) vce(robust) ||id:
Model 1: meglm depvar i.treat i.period i.treat#i.ttime covariates, family(ordinal) link(logit) vce(robust) ||id:
Model 2: meglm depvar i.treat##i.period covariates, family(ordinal) link(logit) vce(robust) ||id:
If I understand it correctly, specification of Model 1 is recommended at https://stats.stackexchange.com/ques...e-time-periods
My questions are:
1) If Model 1 is correctly specified, how can I get the treatment effects for each period? If I am right, in Model 1 the interaction coefficient is the overall treatment effect for both periods, but not for each period separately. Is it simply Model 2?
2) My interpretation of Model 2 would be that the interaction coefficients "treatment#1" and "treatment#2" are the treatment effect from period 0 to 1 and 0 to 2, respectively. Therefore I would interpret the coefficients like I would in a standard Diff-in-Diff Model (Model 0). Is this interpretation correct?
On the other hand I think I need a variable like "ttime" with only 0 and 1 to call it a Diff-in-Diff Model. So I am a little bit confused.
3) If I want to use the "margins" and "marginsplot" command to show the different effects on probability between treatment and control group over time (period), how can I do this for Model 1?
I tried "margins, dydx(treat) at(period=(0 1 2))" but this is "(not estimable)". Probably because of the missing interaction of "treat" with "period"?
As "margins, dydx(treat) at(period=(0 1 2))" works perfectly for Model 2, this is a reason, why I think about estimating Model 2, but I am not sure, if I understand the model and output correctly.
Thank you very much in advance!
All the best,
Sigi
I have already read a lot of things about specifying a Diff-in-Diff model, but there is still something I didn't get. I want to estimate a Diff-in-Diff model where the treatment lasts over two time periods and I want to estimate the treatment effects for both periods. Therefore I have an idea how I should estimate the model (Model 1), but I also think about a similar model (Model 2), where I don't really get the point, if it is still a Diff-in-Diff model or not.
My variables are labelled as follows:
depvar: ordinal (0-4)
treat: 0 for control, 1 for treatment
ttime: 0 for the period before treament, 1 for the periods after treatment
period: 0-2
covariates
I estimated my models as follows after "xtset id period"
Model 0: meglm depvar i.treat##i.ttime covariates, family(ordinal) link(logit) vce(robust) ||id:
Model 1: meglm depvar i.treat i.period i.treat#i.ttime covariates, family(ordinal) link(logit) vce(robust) ||id:
Model 2: meglm depvar i.treat##i.period covariates, family(ordinal) link(logit) vce(robust) ||id:
If I understand it correctly, specification of Model 1 is recommended at https://stats.stackexchange.com/ques...e-time-periods
My questions are:
1) If Model 1 is correctly specified, how can I get the treatment effects for each period? If I am right, in Model 1 the interaction coefficient is the overall treatment effect for both periods, but not for each period separately. Is it simply Model 2?
2) My interpretation of Model 2 would be that the interaction coefficients "treatment#1" and "treatment#2" are the treatment effect from period 0 to 1 and 0 to 2, respectively. Therefore I would interpret the coefficients like I would in a standard Diff-in-Diff Model (Model 0). Is this interpretation correct?
On the other hand I think I need a variable like "ttime" with only 0 and 1 to call it a Diff-in-Diff Model. So I am a little bit confused.
3) If I want to use the "margins" and "marginsplot" command to show the different effects on probability between treatment and control group over time (period), how can I do this for Model 1?
I tried "margins, dydx(treat) at(period=(0 1 2))" but this is "(not estimable)". Probably because of the missing interaction of "treat" with "period"?
As "margins, dydx(treat) at(period=(0 1 2))" works perfectly for Model 2, this is a reason, why I think about estimating Model 2, but I am not sure, if I understand the model and output correctly.
Thank you very much in advance!
All the best,
Sigi