Hi, I have a dataset containing 2 values per person per year: the distance they ran that year and the total time per year it took them. Furthermore I have their agegroup. In SAS VA I've created an aggregated measure: SpeedAv = Sum [_ByGroup_] ('distance'n) / Sum [_ByGroup_] ('time'n), to calculate the average speed per person, but also to be able to see this per agegroup per year. Now I want to create a variable (SpeedDiff) that gives me the differences in SpeedAv from year to year per agegroup. I thought I would be able to do so by right-clicking my aggregated SpeedAv-variable and choosing Create > Difference from Previous Period using Year, but when I right-click my aggregated measures this option isn't shown. Apparently SAS VA doesn't have this option for aggregated measures? Does anyone know a work-around to achieve my goal? Thanks in advance! Dataset (or see the attached excel-file): Person_ID AgeGroup Year Distance (km) Time (hr) A 16-25 2017 100 7,5 A 16-25 2018 200 14,7 A 16-25 2019 250 18,1 B 16-25 2017 500 40 B 16-25 2018 400 34,5 B 16-25 2019 800 68,3 C 26-35 2017 1000 81 C 26-35 2018 1100 85 C 26-35 2019 1500 120 D 26-35 2017 50 3,5 D 26-35 2018 75 5,7 D 26-35 2019 60 4,7 Output I'm looking for (or see the attached excel-file): AgeGroup Year Distance (km) Time (hr) SpeedAV (km/hr) SpeedDiff 16-25 2017 600 47,5 12,6 16-25 2018 600 49,2 12,2 -0,4 16-25 2019 1050 86,4 12,2 0,0 26-35 2017 1050 84,5 12,4 26-35 2018 1175 90,7 13,0 0,5 26-35 2019 1560 124,7 12,5 -0,4
... View more