Hello Stata Community!
I'm new to Callaway and Sant'anna's CSDID/DRDID package. I have two hypotheses with staggered treatments. I've used the CSDID command successfully on my first hypothesis, but I am thinking that I need a triple difference model for my second hypothesis.
I am wondering if there is a way that I can force the CSDID command to accept an interaction term. The way that we specify the treatment, gvar(), makes me uncertain of whether this will work.
My variables are as follows:
factory - 0 for every year before the unit gets a factory and 1 for every year after it gets its first factory
foodprices - a continuous variable of the global food market price in a given year
foodpricesXfactory - an interaction term of the above two variables.
firsttreated - the gvar() specification variable for the first year that a given unit gets its first factory and 0 for all units that never get a factory
unrest - my outcome variable which captures the count of protest in a given unit-year
My general model that I am attempting via CSDID is:
Y = β1Factory + β2Food Prices + β3(Factory x Food Prices) + ε
When I put it into the Stata command, it looks like:
csdid unrest factory foodprices foodpricesXfactory, ivar(unit) time(year) gvar(firsttreated)
This command runs, but I am not sure that it is outputting intelligible results. If not, I am not sure how to account for a staggered treatment in other Stata DID packages. Could someone provide insight on whether this regression is properly handling the interaction term considering the structure of the command?
Thank you so much and please respond if any clarification is needed!
I'm new to Callaway and Sant'anna's CSDID/DRDID package. I have two hypotheses with staggered treatments. I've used the CSDID command successfully on my first hypothesis, but I am thinking that I need a triple difference model for my second hypothesis.
I am wondering if there is a way that I can force the CSDID command to accept an interaction term. The way that we specify the treatment, gvar(), makes me uncertain of whether this will work.
My variables are as follows:
factory - 0 for every year before the unit gets a factory and 1 for every year after it gets its first factory
foodprices - a continuous variable of the global food market price in a given year
foodpricesXfactory - an interaction term of the above two variables.
firsttreated - the gvar() specification variable for the first year that a given unit gets its first factory and 0 for all units that never get a factory
unrest - my outcome variable which captures the count of protest in a given unit-year
My general model that I am attempting via CSDID is:
Y = β1Factory + β2Food Prices + β3(Factory x Food Prices) + ε
When I put it into the Stata command, it looks like:
csdid unrest factory foodprices foodpricesXfactory, ivar(unit) time(year) gvar(firsttreated)
This command runs, but I am not sure that it is outputting intelligible results. If not, I am not sure how to account for a staggered treatment in other Stata DID packages. Could someone provide insight on whether this regression is properly handling the interaction term considering the structure of the command?
Thank you so much and please respond if any clarification is needed!
Comment