Hello there,

I am currently working with a panel dataset, and am having trouble with an issue I hope some of you will have an asnwer to.
First of all, my id variable is called pidp and my time variable is wave. I have data for 27 years (The wave variable goes from wave = 1 to wave = 27).
I am working with a further variable, fimnlabgrs_dv, which expresses each individual's labour income.

Also, I have another variable, called yrbracket, which expresses many age brackets. It basically tells us if the individual is of age under 16, between 16 and 24, between 25 and 34, between 35 and 49, between 50 and 64 or if the person is 65 or older.

I am interested in the yearly average labour income for every yrbracket category; that is, I want to work with the yearly average labour income for people between 16 and 24 years of age; the yearly average labour income for people between 25 and 44 years of age and so on.
What I'm looking to do is to have a variable which expresses the average labour income for every category, for every year. That is, I want a variable with 27 observations, where every observation expresses the yearly average labour income for a specific category and a specific year (the observations need to be 27 as I have data for 27 years). Of course, this means that there will be as many new variables as there are yrbracket categories, which therefore means 6 variables.In this way, I will then be able to plot these new variables and compared them overtime.

Please do let me know if something was not clear in the description of my problem.

Thank you in advance