wassDist function

Compute the Wasserstein distance between to finite distributions.

Compute the Wasserstein distance between to finite distributions.

wassDist(a, b, distMat, p = 1)

Arguments

  • a, b: Vectors representing probability distributions.
  • distMat: Cost matrix.
  • p: cost exponent.

Returns

The Wasserstein distance.

  • Maintainer: Max Sommerfeld
  • License: GPL-2
  • Last published: 2017-03-07

Useful links