One more question. I now have a column with a ranking 1-4. I want to add an other column which shows just the value of the top 1 rank. The rank 2-4 should be blank. The orange column is the column I want to add. Because for further calculations in Visual Analytics I just need the top 1 ranking. Thank you in advance 🙂
ID -- Location -- Section -- Date -- Time -- Type -- Value -- Ranking1-4 -- Ranking1 (2-4)
01 -- Germany -- AA --1/1/20 -- 10:10 -- VW -- 9,0 -- 1 -- 9,0
02 -- Germany -- AA --1/1/20 -- 11:20 -- AU -- 7,0 -- 2 this should be blank
03 -- Germany -- AA --1/1/20 -- 13:50 -- AU -- 6,0 --3 this should be blank
04 -- Germany -- AA --1/1/20 -- 13:50 -- AU -- 5,7 --4 this should be blank
05 -- Germany -- BB --1/1/20 -- 15:10 -- MC -- 15,3 --1 -- 15,3
06 -- Germany -- BB --1/1/20 -- 19:10 -- VW -- 12,0 --2 this should be blank
07 -- Germany -- BB --1/1/20 -- 15:20 -- OP -- 6,7 --3 this should be blank
08 -- Germany -- BB --1/1/20 -- 15:20 -- AU -- 2,0 --4 this should be blank
09 -- Germany -- AA --2/1/20 -- 16:16 -- MC -- 9,5 --1 --9,5
10 -- Germany -- AA --2/1/20 -- 11:45 -- MC -- 5,8 --2 this should be blank
11 -- Germany -- AA --2/1/20 -- 09:40 -- OP -- 2,7 --3 this should be blank
12 -- Germany -- AA --2/1/20 -- 02:40 -- VW -- 2,0 --4 this should be blank
In the previous step I gave you, expand the "then" branch with do-end, and set ranking1 in the block (along with ranking = 1) to value.
Just try your hand, it's not rocket science at all. I gave you all the information you need in my previous post.
It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.
Check out this tutorial series to learn how to build your own steps in SAS Studio.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.