I have a difference-in-difference model with two years in the pre-event period and two years in the post-event period and am running a regression like the following:
1) reg yvar treat_post treat post
Where treat_post is the interaction of the variables treat and post.
My question is about using coefplot to plot regression coefficients for a model similar to the following:
2) reg yvar treat_tminus2 treat_tminus1 treat_tzero treat_tplus1 treat post
Where treat_tminus2 is the interaction of treat and a dummy variable that takes on the value of one in year t-2 (similarly for the other variables).
The goal is to graph the coefficients on the time trend variables to illustrate the trend relative to a baseline year. I understand that the treat_* variables in equation 2) are co-linear with each other, but I've included them all by design so that I can use the omitted option with coefplot. Here's the coefplot post estimation command I'm using:
3) coefplot, omitted drop(treat post _cons) vertical yline(0)
This does exactly what I want by plotting all of the trend variable coefficients and none of the others, and with the omitted option STATA chooses a baseline year that appears on the graph equal to zero.
The problem is that I run the same regression and graph for multiple dependent variables, but sometimes STATA chooses to omit treat_tminus2 as the baseline year and other times it chooses to omit treat_tplus1. Is there a way to select what variable STATA omits from the regression in 2) due to collinearity? I'd like to have a consistent baseline year (probably treat_tminus2) for all of my graphs.
Thank you for the help.
1) reg yvar treat_post treat post
Where treat_post is the interaction of the variables treat and post.
My question is about using coefplot to plot regression coefficients for a model similar to the following:
2) reg yvar treat_tminus2 treat_tminus1 treat_tzero treat_tplus1 treat post
Where treat_tminus2 is the interaction of treat and a dummy variable that takes on the value of one in year t-2 (similarly for the other variables).
The goal is to graph the coefficients on the time trend variables to illustrate the trend relative to a baseline year. I understand that the treat_* variables in equation 2) are co-linear with each other, but I've included them all by design so that I can use the omitted option with coefplot. Here's the coefplot post estimation command I'm using:
3) coefplot, omitted drop(treat post _cons) vertical yline(0)
This does exactly what I want by plotting all of the trend variable coefficients and none of the others, and with the omitted option STATA chooses a baseline year that appears on the graph equal to zero.
The problem is that I run the same regression and graph for multiple dependent variables, but sometimes STATA chooses to omit treat_tminus2 as the baseline year and other times it chooses to omit treat_tplus1. Is there a way to select what variable STATA omits from the regression in 2) due to collinearity? I'd like to have a consistent baseline year (probably treat_tminus2) for all of my graphs.
Thank you for the help.
Comment