The Excel RANK function returns the RANK of a numeric value when compared to a list of other numeric values.
Purpose of Excel RANK Function
RANK function can be used when you want to rank a number against a list of numbers.
Return value
It returns a number that represents the relative RANK of the number against the list of numbers.
Syntax
=RANK (number, array, [order])
Arguments
Arguments | Description | Remarks |
number | The number to RANK. | Mandatory |
array | An array that contains the numbers to RANK against. | Mandatory |
order | Whether to RANK in ascending or descending order. | Optional |
Usage notes
- If Order is: 0 – Highest number gets 1st RANK.
- If Order is 1 – Lowest numbers get 1st RANK.
- If the order parameter is omitted, it assumes order is 0 (descending order).
- If data does not contain a value in any cell or element, RANK will return the #N/A error.
- It is not necessary to sort the values in the list before using the RANK function.
- RANK gives duplicate numbers the same rank. However, the presence of duplicate numbers affects the ranks of subsequent numbers. For example, in a list of integers sorted in ascending order, if the number 10 appears twice and has a rank of 5, then 11 would have a rank of 7 (no number would have a rank of 6).
Availability
Since 2007 for Windows.
Since 2011 for Mac.