Difference between revisions of "Documentation/How Tos/Calc: PERCENTRANK function"
From Apache OpenOffice Wiki
< Documentation | How Tos
(→Syntax:: used r for rank) |
m |
||
(11 intermediate revisions by 5 users not shown) | |||
Line 1: | Line 1: | ||
− | __NOTOC__ | + | {{DISPLAYTITLE:PERCENTRANK function}} |
+ | {{Documentation/CalcFunc StatisticalTOC | ||
+ | |ShowPrevNext=block | ||
+ | |PrevPage=Documentation/How_Tos/Calc:_PERCENTILE_function | ||
+ | |NextPage=Documentation/How_Tos/Calc:_QUARTILE_function | ||
+ | }}__NOTOC__ | ||
== PERCENTRANK == | == PERCENTRANK == | ||
Line 11: | Line 16: | ||
: <tt>'''PERCENTRANK'''</tt> internally assigns a rank ''r'' to <tt>'''number'''</tt>, where 0 is the rank of the lowest number, 1 of the next lowest and so on. If <tt>'''number'''</tt> is not in <tt>'''numberlist'''</tt>, it is assigned a fractional rank proportionately between the rank of the numbers on either side (see the examples). Where ''N'' is the count of numbers in <tt>'''numberlist'''</tt>, <tt>'''PERCENTRANK'''</tt> returns ''r'' / (''N''-1), which is a fraction between 0 and 1 inclusive. | : <tt>'''PERCENTRANK'''</tt> internally assigns a rank ''r'' to <tt>'''number'''</tt>, where 0 is the rank of the lowest number, 1 of the next lowest and so on. If <tt>'''number'''</tt> is not in <tt>'''numberlist'''</tt>, it is assigned a fractional rank proportionately between the rank of the numbers on either side (see the examples). Where ''N'' is the count of numbers in <tt>'''numberlist'''</tt>, <tt>'''PERCENTRANK'''</tt> returns ''r'' / (''N''-1), which is a fraction between 0 and 1 inclusive. | ||
− | : This function is of limited use with a small list of numbers. It may be useful for example when determining where a score lies within all scores for a test, in which case the formula returned can be stated as ''L'' / (''N''-1), where ''L'' is the count of | + | : This function is of limited use with a small list of numbers. It may be useful for example when determining where a score lies within all scores for a test, in which case the formula returned can be stated as ''L'' / (''N''-1), where ''L'' is the count of scores which are lower than <tt>'''number'''</tt>. |
=== Example: === | === Example: === | ||
Line 23: | Line 28: | ||
<tt>'''PERCENTRANK({9; 3; 7; 8}; 6)'''</tt> | <tt>'''PERCENTRANK({9; 3; 7; 8}; 6)'''</tt> | ||
− | : returns <tt>'''0.25'''</tt>. The lowest number <tt>'''3'''</tt> is assigned rank 0; the next highest number <tt>'''7'''</tt> is assigned rank 1. <tt>'''6'''</tt> is assigned a rank proportionately between these, 0.75. There are 4 numbers in the list, so the result is calculated as 0.75/(4-1) = 0.75/3 = 0.25. | + | : returns <tt>'''0.25'''</tt>. The lowest number <tt>'''3'''</tt> is assigned rank '0'; the next highest number <tt>'''7'''</tt> is assigned rank '1'. <tt>'''6'''</tt> is assigned a rank proportionately between these, rank '0.75'. There are 4 numbers in the list, so the result is calculated as 0.75/(4-1) = 0.75/3 = 0.25. |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
===Issues: === | ===Issues: === | ||
* Despite its name, <tt>'''PERCENTRANK'''</tt> returns a fraction, not a percentage. | * Despite its name, <tt>'''PERCENTRANK'''</tt> returns a fraction, not a percentage. | ||
+ | |||
+ | {{SeeAlso|EN| | ||
+ | * [[Documentation/How_Tos/Calc: RANK function|RANK]] | ||
+ | * [[Documentation/How_Tos/Calc: PERCENTILE function|PERCENTILE]] | ||
+ | |||
+ | * [[Documentation/How_Tos/Calc: Statistical functions|Statistical functions]] | ||
+ | |||
+ | * [[Documentation/How_Tos/Calc: Functions listed alphabetically|Functions listed alphabetically]] | ||
+ | * [[Documentation/How_Tos/Calc: Functions listed by category|Functions listed by category]]}} | ||
+ | [[Category: Documentation/Reference/Calc/Statistical functions]] |