[][src]Function kendalls::tau_b

pub fn tau_b<T>(x: &[T], y: &[T]) -> Result<f64, Error> where
    T: Ord + Clone + Default

Implementation of Kendall's Tau-b rank correlation between two arrays.

The definition of Kendall’s tau that is used is:

tau = (P - Q) / sqrt((P + Q + T) * (P + Q + U))

where P is the number of concordant pairs, Q the number of discordant pairs, T the number of ties only in x, and U the number of ties only in y. If a tie occurs for the same pair in both x and y, it is not added to either T or U.