Hello,
I am working on the following Diff in diff model in stata:
reg ln_sales = i.treatment +treatment_after + i.week
This is a DID where I'm looking at the treatment effect on sales for four different grocery stores when a dollar store opens nearby. "Treatment" is a dummy that equals 1 for the treatment group (i.e. when one of the four stores is observed), and "treatmet_after" is an interaction term that takes the value 1 if one of the four stores are observed on a date after the treatment. The sales are average weekly sales over a time span of three years.
I've come to understand that one of the biggest problems in DID models is autocorrelation.
Since the most common AC tests do not work for panel data, I've tried to use the command xtserial, which is based on the Woolridge test. However, it only works when I omit the variable i.treatment as independent variable, which makes me suspect that the Woolridge test is not suited for a DiD model. Am I correct? I've tried to write out the DiD and differentiate it as this article suggests and honestly, I'm a bit confused about how this can be interpreted for a DiD.
Are there any other ways I can detect autocorrelation in a DiD?
Also, it would be grat to know the potential reasons for autocorrelation. I can imagine that the model's errors will correlate every easter, christmas etc, as sales fluctuate differently in these time periods. However, won't the weekly dummies adjust for this? Or are there other factors I should think of?
Related Posts with Detecting autocorrelation in DiD: can I use xtserial?
Import Matlab dataset to StataHi, Is there any way Stata can import MATLAB Data (.mat)? I cannot seem to be able to upload the da…
Adding symbol prefix to formatted table cellHi all, I would like to prefix specific formatted table cells with symbols e.g."<" 0.001 Becaus…
Display Median for Paired t testHello folks I have a data set with several observations at different times for companies. However, …
Loop over different dependent and independent variables[I am using STATA 15.0] I am trying to run ANCOVA regression and store the results using eststo and …
Import 'dd.mm.yy' format date to StataHi, I would like to import the following dates "Date" to Stata date format. Anyone has delt with th…
Subscribe to:
Post Comments (Atom)
0 Response to Detecting autocorrelation in DiD: can I use xtserial?
Post a Comment