This is documentation for an old release of SciPy (version 0.12.0). Read this page in the documentation of the latest stable release (version 1.15.1).
Tie correction factor for ties in the Mann-Whitney U and Kruskal-Wallis H tests.
Parameters : | rankvals : 1-d array_like
|
---|---|
Returns : | factor : float
|
See also
References
[R200] | Siegel, S. (1956) Nonparametric Statistics for the Behavioral Sciences. New York: McGraw-Hill. |
Examples
>>> tiecorrect([1, 2.5, 2.5, 4])
0.9
>>> ranks = rankdata([1, 3, 2, 4, 5, 7, 2, 8, 4])
>>> ranks
array([ 1. , 4. , 2.5, 5.5, 7. , 8. , 2.5, 9. , 5.5])
>>> tiecorrect(ranks)
0.9833333333333333