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