Hello
I am new to the forum and I am editing my last post in which I posted a picture of the data only to realise later that I shouldn't be doing it in that manner.
I am trying to use the "csdid" command in stata which is for treatment with multiple time periods and I have a dataset of about 64 countries of which 38 are treated and 26 are never treated. While I do have treatment year for the "treated group" but nothing for the "never-treated/control group". So, for the treated group I have taken 3 years for each post and pre-treatment year (so for each country it's 6 years in total), while I have taken data for the control group from 1987-2021. Hence, whenever I run my estimation, I'm getting a very high standard error.
I was hoping to get some help regarding this issue wherein if there is a way to accurately decide which years should be used for the control group so that I run the code correctly.
I would be very grateful if someone can help me out with this, I will put a glimpse of how my data looks.
Thank you
I am new to the forum and I am editing my last post in which I posted a picture of the data only to realise later that I shouldn't be doing it in that manner.
I am trying to use the "csdid" command in stata which is for treatment with multiple time periods and I have a dataset of about 64 countries of which 38 are treated and 26 are never treated. While I do have treatment year for the "treated group" but nothing for the "never-treated/control group". So, for the treated group I have taken 3 years for each post and pre-treatment year (so for each country it's 6 years in total), while I have taken data for the control group from 1987-2021. Hence, whenever I run my estimation, I'm getting a very high standard error.
I was hoping to get some help regarding this issue wherein if there is a way to accurately decide which years should be used for the control group so that I run the code correctly.
I would be very grateful if someone can help me out with this, I will put a glimpse of how my data looks.
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input str3 country int year float hcpi_a byte treat "ALB" 2006 2.41 0 "ALB" 2007 2.91 0 "ALB" 2008 3.41 0 "ALB" 2009 2.29 1 "ALB" 2010 3.57 1 "ALB" 2011 3.41 1 "ALB" 2012 2.03 1 "ARM" 2003 4.54 0 "ARM" 2004 5.93 0 "ARM" 2005 .72 0 "ARM" 2006 3.43 1 "ARM" 2007 4.55 1 "ARM" 2008 9.02 1 "ARM" 2009 3.54 1 "AFG" 1987 18.4 0 "AFG" 1988 27.5 0 "AFG" 1989 71.5 0 "AFG" 1990 47.4 0 "AFG" 1991 43.8 0 "AFG" 1992 58.19 0 "AFG" 1993 33.99 0 "AFG" 1994 20.01 0 "AFG" 1995 14 0 "AFG" 1996 14.01 0 "AFG" 1997 14.01 0 "AFG" 1998 14.01 0 "AFG" 1999 14.01 0 "AFG" 2000 0 0 "AFG" 2001 -43.4 0 "AFG" 2002 51.93 0 "AFG" 2003 35.66 0 "AFG" 2004 16.36 0 "AFG" 2005 10.57 0 "AFG" 2006 6.78 0 "AFG" 2007 8.68 0 "AFG" 2008 26.42 0 "AFG" 2009 -6.81 0 "AFG" 2010 2.18 0 "AFG" 2011 11.8 0 "AFG" 2012 6.44 0 "AFG" 2013 7.39 0 "AFG" 2014 4.67 0 "AFG" 2015 -.66 0 "AFG" 2016 4.38 0 "AFG" 2017 4.98 0 "AFG" 2018 .63 0 "AFG" 2019 2.3 0 "AFG" 2020 5.44 0 "AFG" 2021 5.06 0 "AGO" 1987 1.83 0 "AGO" 1988 1.83 0 "AGO" 1989 1.83 0 "AGO" 1990 1.83 0 "AGO" 1991 85.26 0 "AGO" 1992 299.1 0 "AGO" 1993 1379.48 0 "AGO" 1994 949.77 0 "AGO" 1995 2672.23 0 "AGO" 1996 4146.01 0 "AGO" 1997 221.49 0 "AGO" 1998 107.43 0 "AGO" 1999 248.25 0 "AGO" 2000 325.03 0 "AGO" 2001 152.59 0 "AGO" 2002 108.89 0 "AGO" 2003 98.22 0 "AGO" 2004 43.53 0 "AGO" 2005 22.96 0 "AGO" 2006 13.31 0 "AGO" 2007 12.25 0 "AGO" 2008 12.47 0 "AGO" 2009 13.72 0 "AGO" 2010 14.48 0 "AGO" 2011 13.48 0 "AGO" 2012 10.28 0 "AGO" 2013 8.78 0 "AGO" 2014 7.3 0 "AGO" 2015 9.16 0 "AGO" 2016 32.38 0 "AGO" 2017 29.84 0 "AGO" 2018 19.63 0 "AGO" 2019 17.08 0 "AGO" 2020 21.02 0 "AGO" 2021 23.85 0 end
Thank you

Comment