Hi to everyone,
Im new in Stata programing, and it would be very helpful if someone gave me an opinion about my two problems .
First: I am trying to create a panel setting. woriking with sales data across several countries. Im trying to find the effect on saleid which is the effect of one particular law on the specific products (which are quoted by id) on specific time periods (example december 2013 or july 2012). as you can see in the first attachment.
i have already created a group indicator using the commands: egen id1=group(id) and egen date2=group(date) (attachment 2) but when ive try to create the pannel setting using the comand xtset id1 date2 i always get the following comand : repeated time values within panel r(451); also when run only xtset id1 i tells me that the pannel is unbalanced. the only command that i managed to find in internet was to drop if date==date[_n-1] however im not fully covinced that this is a proper way to deal with my data.
my question is can I just go on with xtreg command even in the case of unbalanced pannel, will my estimators be biased ?
Second: in my regression I also trying to enter two fixed effects. the product-date fixed effect and the country-year fixed effect, so that to account for trends in the product and countries. i was just wondering if just an intenaction term between the variables of country and year would do the trick?
Any idea or advice would be highly appreciated.
Related Posts with Panel Setting problem, and country-year fixed effects
Merging two datasets with specific dates of start and end of period within a yearI am running on panel project where I have to merge and match two dataset . My first dataset is a se…
Creating variables out of duplicatesHi, as this is my first post, I hope I meet all the criteria. I am using a large panel data set on a…
Why doesn't clustering change anything?Hi all, I have panel data xtset across 3 waves of children's weight and parents employment status, …
Marginal effects on predicted marginal probability after mvprobitHi! I ran a multivariate probit regression on 3 binary dependent variables using Capellari and Jenki…
How to drop a group of observation if at least one of them present a characteristicHi Statalist I'm analysing a household dataset. I'm interested in performing a command only if at …
Subscribe to:
Post Comments (Atom)
0 Response to Panel Setting problem, and country-year fixed effects
Post a Comment