I am working on analyzing whether a policy implemented in 2011 impacted the companies that adopted it. Below are the details:
Dataset:
I have created three variables:
I am trying to run the following code, but I am not sure if I am doing it correctly:
Dataset:
- The dependent variable Y is measured from 2006 to 2016
- Treatment Year: 2011
- #Companies that implemented the policy = 33
- #Companies that did not implement the policy = 335
- Does the policy have an impact on Y?
- For the companies which implemented the policy: For the dependent variable change from 2006 to 2016, what % of change was due to the policy implementation?
I have created three variables:
- Treatment variable ('treatment'): 0 assigned to companies in the control group and 1 assigned to companies in the treatment group
- Time Variable ('time'): 0 for years 2006 to 2010 and 1 for years from 2011 to 2016
- Treatment*Time variable ('treatment_time'): It is 1 for companies in the treatment group and time>=2011
- companyID - one for each company in the dataset
- year - I have recoded it such that 2006 is 1, 2007 is 2, ....., and 2016 is 11.
- y - dependent variable
I am trying to run the following code, but I am not sure if I am doing it correctly:
- xtreg y time##treatment, r
- reg incrate post_t##treatment, r
- reg y time treatment treatment_time, r
- xtdidregress (y) (treatment_time), group(companyid) time(year)
Comment