Using the Rank function

Occasional Contributor
Posts: 5

Using the Rank function

I'm trying to use the rank function in SAS but I'm not sure I'm using it correctly or there may be another function that works better.

The data I have is made up of storm names and states associated with each storm. I have run a formula showing me by storm which states have the largest percentage of records i.e.

Storm 1:

KS = 60%

MO = 15%

IL = 10%

OH = 6%

AR = 5%

TX = 2%

KY = 2%

Is there a way to rank (by storm) the states that have the largest % of records?

Super User
Posts: 13,508

Re: Using the Rank function

How have you tried so far?

You may only need to 1) sort by storm and 2) include a BY storm statement in Proc Rank;

Ask a Question
Discussion stats
  • 1 reply
  • 2 in conversation