Minimize the entropic Wasserstein distance

Wp(mu_vals, mu_probs, nu_vals, nu_probs, p)

Arguments

mu_vals, nu_vals

numeric vector of values of discrete distribution

mu_probs, nu_probs

numeric vector of probabilities of discrete distribution

p

exponent of L_p distance

Examples

Wp(c(1,2,3), c(1/3, 1/3, 1/3), c(2,3,4), c(1/4, 1/4, 1/2), 1)
#> [1] 1.25