public class KolmogorovSmirnovDistanceFunction extends AbstractNumberVectorDistanceFunction
This distance function assumes there exist a natural order in the vectors, i.e. they should be some 1-dimensional histogram.
The distance is then defined as \[\text{KS}(\vec{x},\vec{y}) := \max_i |\frac{\sum_{j=1}^i x_j}{\sum_{j=1}^d x_j}| - |\frac{\sum_{j=1}^i y_j}{\sum_{j=1}^d y_j}| \] which is the maximum difference of the empirical CDFs, where the divisors normalize the distribution to 1.
| Modifier and Type | Class and Description |
|---|---|
static class |
KolmogorovSmirnovDistanceFunction.Parameterizer
Parameterization class, using the static instance.
|
| Modifier and Type | Field and Description |
|---|---|
static KolmogorovSmirnovDistanceFunction |
STATIC
Static instance.
|
| Constructor and Description |
|---|
KolmogorovSmirnovDistanceFunction()
Deprecated.
Use static instance!
|
| Modifier and Type | Method and Description |
|---|---|
double |
distance(NumberVector v1,
NumberVector v2)
Computes the distance between two given vectors according to this distance
function.
|
boolean |
equals(java.lang.Object obj) |
int |
hashCode() |
java.lang.String |
toString() |
dimensionality, dimensionality, dimensionality, dimensionality, dimensionality, dimensionality, dimensionality, dimensionality, getInputTypeRestrictionclone, finalize, getClass, notify, notifyAll, wait, wait, waitinstantiateisMetric, isSquared, isSymmetricpublic static final KolmogorovSmirnovDistanceFunction STATIC
@Deprecated public KolmogorovSmirnovDistanceFunction()
public double distance(NumberVector v1, NumberVector v2)
NumberVectorDistanceFunctionv1 - first vectorv2 - second vectorpublic java.lang.String toString()
toString in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.ObjectCopyright © 2019 ELKI Development Team. License information.