Hi,
I have very detailed panel data about sales - that means for each week and store I have data about approx. 80 products - their price and volume of sales. But my data have this structure
week - store - item - price - sales
1 - 1 - 1 - 5 - 3
1 - 1 - 2 - 6 - 2
1 - 2 - 1 - 5 - 4
1 - 2 - 2 - 7 - 0
2 - 1 - 1 - 6 - 2
2 - 1 - 2 - ..
2 - 2 - 1 - ..
2 - 2 - 2 - ..
3 - ...
if I try xtset command, stata tells me "repeated time values within panel" which makes sence since there are data about multiple products.
It seems to me that the right thing to do here would be to set the products as separate variables (so to have price of item1, price of item2, sales of item1, sales of item2, ...). How do I change the data structure to be able to use panel tools in Stata?
Or is there some way to tell Stata some more info about the panel data so that I could be using xt functions? My aim here is a fixed-effects panel regression...
Thank you for any tips!
Tom
I have very detailed panel data about sales - that means for each week and store I have data about approx. 80 products - their price and volume of sales. But my data have this structure
week - store - item - price - sales
1 - 1 - 1 - 5 - 3
1 - 1 - 2 - 6 - 2
1 - 2 - 1 - 5 - 4
1 - 2 - 2 - 7 - 0
2 - 1 - 1 - 6 - 2
2 - 1 - 2 - ..
2 - 2 - 1 - ..
2 - 2 - 2 - ..
3 - ...
if I try xtset command, stata tells me "repeated time values within panel" which makes sence since there are data about multiple products.
It seems to me that the right thing to do here would be to set the products as separate variables (so to have price of item1, price of item2, sales of item1, sales of item2, ...). How do I change the data structure to be able to use panel tools in Stata?
Or is there some way to tell Stata some more info about the panel data so that I could be using xt functions? My aim here is a fixed-effects panel regression...
Thank you for any tips!
Tom