Hi all, I would like to know what SAS codes I can use to decide the values of three ranking variables (Top1 to Top3) based on multiple existing variables (Score_A to F) as below. Score_A to F are the scores for A, B, C, D, F for each observation. Top1 to 3 are the new variables that I want to create to show among ABCDF, which would go to top1 to top 3 for each observation. Case 1 assigns only one to each of the new variables and Case 2 would assign two if they have the same scores. Thank you in advanced! Case1 Top1 Top2 Top3 Score_A Score_B Score_C Score_D Score_F obs1 A B D 1 0.9 0 0.6 0.6 obs2 D F C 0 0.2 0.6 1 1 Case 2 Top1 Top2 Top3 Score_A Score_B Score_C Score_D Score_F obs1 A B D F 1 0.9 0 0.6 0.6 obs2 D F C B 0 0.2 0.6 1 1
... View more