| NMathFunctionsMedian(DoubleVector) Method |
Calculates the median value of a given vector's elements.
Namespace: CenterSpace.NMath.CoreAssembly: NMath (in NMath.dll) Version: 7.4
Syntax public static double Median(
DoubleVector v
)
Public Shared Function Median (
v As DoubleVector
) As Double
public:
static double Median(
DoubleVector^ v
)
static member Median :
v : DoubleVector -> float
Parameters
- v DoubleVector
- A vector.
Return Value
DoubleThe median value of the elements in
v.
Exceptions Remarks
The vector is sorted. If the vector has an odd number of elements
the middle number is returned. Otherwise, the mean of the two
middle numbers is returned.
See Also