You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The total variation distance for probability measures on discrete spaces can be defined as ||p-q|| = ||p-q||₁ / 2 and hence is implemented as the cityblock distance divided by 2 in this package. However, for scalar inputs and vectors of length 1 this implementation is unintuitive since the correspondence to the probabilistic setting is lost: if one identifies a scalar input p with the probability measure (p, 1-p) on a space with two discrete values, the total variation distance of two such probability measures is actually ||(p,1-p) - (q, 1-q)|| = ||(p - q, q - p)|| = ||p-q||₁ and not ||p-q||₁ / 2.
I'm not sure what's the best way to deal with this inconsistency. I guess either one could just stick to the current implementation, ignoring the missing correspondence to the probability theoretical definition, or define the total variation distance in the scalar case (and for vectors of length 1) as the cityblock distance. Or, I guess, one could even think about disallowing scalar inputs.
The text was updated successfully, but these errors were encountered:
The total variation distance for probability measures on discrete spaces can be defined as
||p-q|| = ||p-q||₁ / 2
and hence is implemented as the cityblock distance divided by 2 in this package. However, for scalar inputs and vectors of length 1 this implementation is unintuitive since the correspondence to the probabilistic setting is lost: if one identifies a scalar inputp
with the probability measure(p, 1-p)
on a space with two discrete values, the total variation distance of two such probability measures is actually||(p,1-p) - (q, 1-q)|| = ||(p - q, q - p)|| = ||p-q||₁
and not||p-q||₁ / 2
.I'm not sure what's the best way to deal with this inconsistency. I guess either one could just stick to the current implementation, ignoring the missing correspondence to the probability theoretical definition, or define the total variation distance in the scalar case (and for vectors of length 1) as the cityblock distance. Or, I guess, one could even think about disallowing scalar inputs.
The text was updated successfully, but these errors were encountered: