The RANK function returns the rank or position of a number within a range of numbers.
Duplicate numbers are given the same rank. This then affects the ranking of subsequent numbers. For example, if number 8 appears twice and has a rank of 4, then 9 would have a rank of 6 and no number would be ranked number 5.
The syntax for the RANK function is:
=RANK(number, ref, [order])
|number||The number whose rank you want to find|
|ref||The range of numbers that you want to find the ranking position within|
|order||How to rank the number. 0 for descending order and 1 for ascending.Order is optional and if omitted, 0 is entered|
The example below demonstrates the RANK function being used to position the numbers in a range of cells.