Hello Stata people,
I have a panel dataset where the cross-sectional variable is wage (for different individuals) and the longitudinal variable is time.
I only want a time-series of total(wage) (sum of all employees' wages in a given year). I'm not interested in the wages of individuals.
I have used this command: bysort year: egen tot_wage=total(total_income)
Now I have a time series of the tot_wage variable. Unfortunately, because there were i observations in each year, the tot_wage series is replicated i times in each year. These values appear sequentially e.g.
...
2012 | 5000
2012 | 5000
2012 | 5000
2013 | 5500
2013 | 5500
...
Not ideal.
The individuals participating in the wage survey are not the same from year to year so I can't drop all but one person's observations. How might I obtain the simple time series I am after?
Best,
Pascal
Related Posts with Dropping duplicated results with panel data
combining two bar graphsHi, I am wanting to compare the mean of an outcome amongst male and female children in households wi…
Unexpected omitted variablesHi, I have a question about unexpected omitted variables. When I run a regression with dummy variabl…
Catplot - Varying Base & Intensity Colors Across Multiple GroupsHello, I am using catplot (thanks Nick for the great package) and I am trying to have 2 dimensions …
How to produce this type of graph?Hi, I saw this graph in an article and I wonder if it can be produced by Stata. Shamefully, I do no…
Compare the unexplained wage differential of the Blinder-Oaxaca decomposition between two groupsDear all, after using the Blinder-Oaxaca decompostion to decompose the African American/ White wage …
Subscribe to:
Post Comments (Atom)
0 Response to Dropping duplicated results with panel data
Post a Comment