In my case, I am finding pscore for doing PSM. To get there, I need to run the logistic regression to get the pscore. Thank you Clyde Schechter that I confirm my xtlogit with two way fixed effects.
In my setting, I have 7 countries, all firms in country A have the "treatment" variables equal to 1, otherwise 0.
My logit regression is
while treatment equal to1 if firms in country A and 0 otherwise. firm-level-variables includes firm size, firm age... country-level variables include lngdp, unemployment ....
When running the regression
I got the error immediately
So, I asked myself and think this means that in at least one group, all observations have either a 0 or a 1 as the outcome variable. It makes sense because all observations of firms in country A will have treatment =1 and all observations of firms in other countries will have treatment=0, so they wont vary.
I am not sure whether my understanding is correct. If it is the case, would you please guide me how to overcome the problem. Thank you.
In my setting, I have 7 countries, all firms in country A have the "treatment" variables equal to 1, otherwise 0.
My logit regression is
Code:
xtset firm year xtlogit treatment firm-level-variables country-level-variables i.year, fe
When running the regression
Code:
xtlogit treatment firm_age i.year, fe
Code:
outcome does not vary in any group
I am not sure whether my understanding is correct. If it is the case, would you please guide me how to overcome the problem. Thank you.
Comment