O(nlogn) Compute the Kendall's tau from a vector of paired data. Return NaN when number of pairs <= 1.
Modulestatistics-0.16.3.0Haskell2010
Statistics.Correlation.Kendall
Fast O(NlogN) implementation of Kendall's tau.
This module implements Kendall's tau form b which allows ties in the data. This is the same formula used by other statistical packages, e.g., R, matlab.
\tau = \frac{n_c - n_d}{\sqrt{(n_0 - n_1)(n_0 - n_2)}}where n_0 = n(n-1)/2, n_1 = number of pairs tied for the first quantify, n_2 = number of pairs tied for the second quantify, n_c = number of concordant pairs$, n_d = number of discordant pairs.
- 1 value
- Packagestatistics-0.16.3.0
- Exports1
- LanguageHaskell2010
- LicenceBSD-2-Clause
- SourceKendall.hs
References
0 declarationsWilliam R. Knight. (1966) A computer method for calculating Kendall's Tau with ungrouped data. Journal of the American Statistical Association, Vol. 61, No. 314, Part 1, pp. 436-439. http://www.jstor.org/pss/2282833