@Skillside wrote:
Hi,
this time i would like to calculate mean value from different variables (their highest value). Please, suggest a solution.
data have;
input ID age1 age2 age3 age4 age5 ;
cards;1 1 3 6 9 2
2 6 2 3 4 4
3 7 2 9 0 0;
run;
the mean should be calculated from 9, 6 and 9
Thank You
A hint for future example data sets: If you are going to reference the required values it would be a better idea to have those values unique or explicitly state which value from which record. Max is relatively simple but a more complicated question with both 6 and 9 repeated in different records might be another story.
... View more