In the context of a difference-in-differences analysis, I would like to perform an events study to check for anticipatory and adjustment effects. My ultimate goal is to create a graph such as the one one page 26 of the following paper
I already checked on Stackoverflow and was suggested to use time series operators.
The simplified version of my panel data set contains a time variable "year", and identifier variable "ID", the dummy variable of interest "presence", and a set of various controls
Lead variables
Code:
gen presence_F1= F1.presence gen presence_F2= F2.presence gen presence_F3= F3.presence
Code:
gen presence_L1= L1.presence gen presence_L2= L2.presence gen presence_L3= L3.presence
Code:
reghdfe dependent_variable presence set_of_controls, absorb(year ID)
Code:
reghdfe dependent_variable presence_F3 set_of_controls, absorb(year ID) reghdfe dependent_variable presence_F2 set_of_controls, absorb(year ID) reghdfe dependent_variable presence_F1 set_of_controls, absorb(year ID) reghdfe dependent_variable presence set_of_controls, absorb(year ID) reghdfe dependent_variable presence_L1 set_of_controls, absorb(year ID) reghdfe dependent_variable presence_L2 set_of_controls, absorb(year ID) reghdfe dependent_variable presence_L3 set_of_controls, absorb(year ID)
0 Response to Lagged and leading variable dummy variables for events study
Post a Comment