Hello,
I am currently working with an unbalanced panel data set. We would like run some regressions that include time effects and fixed effects, with standard errors that are robust to autocorrelation, heteroscedasticity, and cross-sectional dependence. We have found that xtscc handles this framework nicely. Thus, my stata code at the moment looks something like (where timevar is a stand-in for my time variable in my data set, and panelvar is a stand-in for my panel variable):
xtscc dependentvar i.timevar i.panelvar
where i.timevar is the my set of time dummies, andi.panelvar is my set of fixed effects dummies.
I would like to test whether the fixed effects are equal--in my regression output, I have a set of estimated time and fixed effects coefficients (where the first time period is taken as a "reference" and the rest of the time dummies are in reference to that time period, and the same for the fixed effects) and a constant. I would then like to use testparm i.panelvar to test whether the fixed effects (in that they are in reference to the first coefficient) are jointly equal to zero (and thus, when not in reference to the first coefficient, are equal to each other).
Using testparm i.panelvar after a standard regress command gives me this test as I expect. However, I think after using testparm i.panelvar after xtscc gives me degrees of freedom in my statistic that correspond to both the time and fixed effects dummies, even though I specified only to test the fixed effects dummies for equality (i.e. F(df1, df2) rather than F(df2,df2)).
I know I can run xtscc i.timevar, fe to capture fixed and time effects as well, but then I'm not sure how to test for equality of the fixed effects in the way I can explicitly on the individual fixed effects dummies from the previous regression. Any tips on how to run a regression with fixed and time effects using xtscc, generating output such that I can test for equality of just the fixed effects to each other?
Thank you for any and all advice!
I am currently working with an unbalanced panel data set. We would like run some regressions that include time effects and fixed effects, with standard errors that are robust to autocorrelation, heteroscedasticity, and cross-sectional dependence. We have found that xtscc handles this framework nicely. Thus, my stata code at the moment looks something like (where timevar is a stand-in for my time variable in my data set, and panelvar is a stand-in for my panel variable):
xtscc dependentvar i.timevar i.panelvar
where i.timevar is the my set of time dummies, andi.panelvar is my set of fixed effects dummies.
I would like to test whether the fixed effects are equal--in my regression output, I have a set of estimated time and fixed effects coefficients (where the first time period is taken as a "reference" and the rest of the time dummies are in reference to that time period, and the same for the fixed effects) and a constant. I would then like to use testparm i.panelvar to test whether the fixed effects (in that they are in reference to the first coefficient) are jointly equal to zero (and thus, when not in reference to the first coefficient, are equal to each other).
Using testparm i.panelvar after a standard regress command gives me this test as I expect. However, I think after using testparm i.panelvar after xtscc gives me degrees of freedom in my statistic that correspond to both the time and fixed effects dummies, even though I specified only to test the fixed effects dummies for equality (i.e. F(df1, df2) rather than F(df2,df2)).
I know I can run xtscc i.timevar, fe to capture fixed and time effects as well, but then I'm not sure how to test for equality of the fixed effects in the way I can explicitly on the individual fixed effects dummies from the previous regression. Any tips on how to run a regression with fixed and time effects using xtscc, generating output such that I can test for equality of just the fixed effects to each other?
Thank you for any and all advice!
Comment