Vector.CorrelationDistance<T> Method

Returns a distance that is a function of the correlation between two vectors.

Definition

Namespace: Numerics.NET
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.2
C#
public static double CorrelationDistance<T>(
	Vector<T> left,
	Vector<T> right
)

Parameters

left  Vector<T>
The first Vector<T>.
right  Vector<T>
The second Vector<T>.

Type Parameters

T

Return Value

Double
The correlation between left and right scaled in such a way that perfect correlation corresponds to a value of 0, and perfect inverse correlation corresponds to a value of 1.

Exceptions

ArgumentNullException

left is null.

-or-

right is null.

DimensionMismatchException

The length of left is not equal to the length of right.

See Also