kuiper2_test

Function kuiper2_test 

Source
pub fn kuiper2_test<T>(
    sample1: Vec<T>,
    sample2: Vec<T>,
) -> Result<TestResult, TestError>
where T: PartialOrd + Copy,
Expand description

Preform 2-sample Kuiper’s test

Kuiper’s test is the modification of the Kolmogorov-Smirnov test. Instead of searching for maximum deviation between empirical cdfs, it uses the following as the test statistic: $$ K = \max{[F_1(x) - F_2(x)]} + \min{[F_1(x) - F_2(x)]} $$

Where $F_i(x)$ is of course empirical cdf for the i-th sample.

The particularly interesting feature of the Kuiper’s test is, that if the support is a circle, the test statistic is invariant under rotation. Thus it is used particularly often for angular distributions. It is also said to be more sensitive ‘at the tails’ of the distribution than KS test.

§References