Compute the Kruskal-Wallis H-test for independent samples
The Kruskal-Wallis H-test tests the null hypothesis that the population median of all of the groups are equal. It is a non-parametric version of ANOVA. The test works on 2 or more independent samples, which may have different sizes. Note that rejecting the null hypothesis does not indicate which of the groups differs. Post-hoc comparisons between groups are required to determine which groups are different.
Parameters : | sample1, sample2, ... : array_like
|
---|---|
Returns : | H-statistic : float
p-value : float
|
Notes
Due to the assumption that H has a chi square distribution, the number of samples in each group must not be too small. A typical rule is that each sample must have at least 5 measurements.
References
[R89] | http://en.wikipedia.org/wiki/Kruskal-Wallis_one-way_analysis_of_variance |