Sage Modeling and Simulation Library

Extensions..::..GetPercentileForItem<(Of <(<'T>)>)> Method (List<(Of <(<'T>)>)>, T, Func<(Of <(<'T, Double>)>)>, Object%)

Gets the percentile for item. Note: with [0,1,2,3,3,3], 3 will be in the 50th percentile.

Namespace:  Highpoint.Sage.Mathematics
Assembly:  Sage4 (in Sage4.dll)

Syntax


public static double GetPercentileForItem<T>(
	this List<T> srcItems,
	T targetItem,
	Func<T, double> valueGetter,
	ref Object pd
)

Type Parameters

T

Parameters

srcItems
Type: List<(Of <(<'T>)>)>
The _SRC items.
targetItem
Type: T
The target item.
valueGetter
Type: Func<(Of <(<'T, Double>)>)>
The value getter.
pd
Type: Object%
The object that will hold state for repeated calls to this method on the same list.

Return Value