Stats.Harmonic Mean As<T, TResult> Method
Returns the harmonic mean of the elements of a vector.
Definition
Namespace: Numerics.NET.Statistics
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.4
C#
The harmonic mean of the elements of values.
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.4
public static TResult HarmonicMeanAs<T, TResult>(
this Vector<T> values
)
Parameters
- values Vector<T>
- A vector.
Type Parameters
- T
- TResult
Return Value
TResultThe harmonic mean of the elements of values.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type Vector<T>. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).Remarks
The harmonic mean is the reciprocal of the arithmetic mean of the reciprocals of the values values.
Exceptions
Argument | values is null. |