Hi Forum,
I am struggling with something very silly but would be very helpful if someone could help me out.
I have an id variable which identifies the product and the size (e.g Coca Cola 600 ml)
Since my analysis is to evaluate a policy impact, I want to make sure that for the same product I have observations for both years.
However, there are some products that I have N observations for one year and 0 for the other, which could bias my research.
I am trying to drop those products who do not have observations for both years so I can compare the changes between them
Any suggestions?
Many thanks!!
Best,
Lena
Related Posts with Matching observations across years for same id
Number format which does not add zeros to natural numbersI want Stata to show decimals only for numbers which are not natural. For instance - I want the numb…
Date formatHello, In the dataset, the date is in format : Code: 2015 - 07 - 01 00:00:00 2016 - 01 - 01 00:00…
Interpretation of long and short run coefficients in ARDL modelHi, I needed some help understanding how to interpret the short and long run coefficients of ARDL m…
Handling duplicatesHello, This is my first post here and I am generally new to Stata, but I'll try to formulate my con…
Turning numeric variable into stata time variableI have a dataset broken into date and time of the day. I want to break this time variable into hour …
Subscribe to:
Post Comments (Atom)
0 Response to Matching observations across years for same id
Post a Comment