Vector.Canberra Distance<T> Method
Returns the Canberra distance between two vectors.
Definition
Namespace: Numerics.NET
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.2
C#
The sum of the ratio of the difference between corresponding components of left and right to the sum of their absolute values.
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.2
public static T CanberraDistance<T>(
Vector<T> left,
Vector<T> right
)
Parameters
Type Parameters
- T
Return Value
TThe sum of the ratio of the difference between corresponding components of left and right to the sum of their absolute values.
Exceptions
Argument | left is null. -or- right is null. |
Dimension | The length of left is not equal to the length of right. |