statistics-0.13.3.0: A library of statistical types, data, and functions

Copyright | (c) 2014 Danny Navarro
License | BSD3
Maintainer | bos@serpentine.com
Stability | experimental
Portability | portable
Safe Haskell | None
Language | Haskell98

Statistics.Test.KruskalWallis

Description

Synopsis

- kruskalWallisRank :: [Sample] -> [Sample]
- kruskalWallis :: [Sample] -> Double
- kruskalWallisSignificant :: [Int] -> Double -> Double -> Maybe TestResult
- kruskalWallisTest :: Double -> [Sample] -> Maybe TestResult

# Documentation

kruskalWallisRank :: [Sample] -> [Sample] #

Kruskal-Wallis ranking.

All values are replaced by the absolute rank in the combined samples.

The samples and values need not to be ordered but the values in the result are ordered. Assigned ranks (ties are given their average rank).

kruskalWallis :: [Sample] -> Double #

The Kruskal-Wallis Test.

In textbooks the output value is usually represented by `K` or `H`. This function already does the ranking.

kruskalWallisSignificant #

Arguments

:: [Int] | The samples' size
-> Double | The p-value at which to test (e.g. 0.05)
-> Double | K value from `kruskallWallis`
-> Maybe TestResult |

Calculates whether the Kruskal-Wallis test is significant.

It uses Chi-Squared distribution for aproximation as long as the sizes are larger than 5. Otherwise the test returns `Nothing`.

kruskalWallisTest :: Double -> [Sample] -> Maybe TestResult #

Perform Kruskal-Wallis Test for the given samples and required significance. For additional information check `kruskalWallis`. This is just a helper function.