Calculates the nth percentile of the elements in a data set.

Namespace:  CenterSpace.NMath.Stats
Assembly:  NMathStats (in NMathStats.dll) Version: 3.4.0.0

Syntax

C#
public static double Percentile(
	int[] data,
	double n
)
Visual Basic (Declaration)
Public Shared Function Percentile ( _
	data As Integer(), _
	n As Double _
) As Double
Visual C++
public:
static double Percentile(
	array<int>^ data, 
	double n
)

Parameters

data
Type: array< System..::.Int32 >[]()[]
An array of integers.
n
Type: System..::.Double
A percentile between 0 and 1.

Return Value

nth percentile.

Exceptions

ExceptionCondition
CenterSpace.NMath.Core..::.InvalidArgumentException Thrown if n is greater than one or less than zero.

See Also