This function checks whether the distance matrix \(D:=d_{ij} = d(x_i, x_j)\) satisfies four axioms to make itself a semimetric, which are (1) \(d_{ii} = 0\), (2) \(d_{ij} > 0\) for \(i\neq j\), (3) \(d_{ij} = d_{ji}\), and (4) \(d_{ij} \leq d_{ik} + d_{kj}\).
checkmetric(d)
"dist"
object or \((N\times N)\) matrix of pairwise distances.
a logical; TRUE
if it satisfies metric property, FALSE
otherwise.