Distance-Measures

chebyshev - (chebyshev)

The distance is calculated as d(x,y) = \max_{i} |x_i-y_i|.

euclidean - (euclidean)

The distance is calculated as d(x,y) = \sqrt{\sum_{i=0}^n (x_i-y_i)^2}.

hamming - (hamming)

The distance is calculated as the number of components which differ over the number of components.

manhattan - (manhattan)

The distance is calculated as d(x,y) = \sum_{i=0}^n |x_i-y_i|.

minkowski - (minkowski)

The distance is calculated as d(x,y) = (\sum_{i=0}^n (x_i-y_i)^p)^{1/p}.

Parameters

p - Parameter of the Minkowski distance (exponent).

  • name: p
  • min: 0.001
  • default:
  • type: float

seuclidean - (seuclidean)

The distance is calculated as d(x,y) = \sqrt{\frac{\sum_{i=0}^n (x_i-y_i)^2}{s^2_i}}, where s^2_i is the standard deviation between the x_i and y_i in the data set.

sqeuclidean - (sqeuclidean)

The distance is calculated as d(x,y) = \sum_{i=0}^n (x_i-y_i)^2.

weuclidean - (weuclidean)

The distance is calculated as d(x,y) = \sqrt{\sum_{i=0}^n w_i(x_i-y_i)^2}.

Parameters

weights - Comma-separated list of weights for each dimension.

  • name: Weigths
  • default:
  • type: string

wminkowski - (wminkowski)

The distance is calculated as d(x,y) = (\sum_{i=0}^n (x_i-y_i)^p)^{1/p}.

Parameters

p - Parameter of the Minkowski distance (exponent).

  • name: p
  • min: 0.001
  • default:
  • type: float

weights - Comma-separated list of weights for each dimension.

  • name: Weights
  • default:
  • type: string