Safe Haskell | Safe |
---|---|

Language | Haskell2010 |

- controlLimit :: Floating a => a -> a
- entropy :: (Foldable t, Floating a) => t a -> a
- ratio :: (Foldable t, RealFrac a1, Fractional a, Floating a1) => t a1 -> a
- pareto :: (Foldable t, RealFrac a, Floating a) => t a -> Bool
- causeEffect :: (RealFrac a1, Fractional b, Fractional a, Enum a) => [a1] -> [(a, b)]
- causesMaxConcentration :: [Float] -> Float
- effectsMaxConcentration :: Num a => [Float] -> Float

# Documentation

controlLimit :: Floating a => a -> a Source #

Determine control limit.

`>>>`

2.7709505944546686`controlLimit 10`

entropy :: (Foldable t, Floating a) => t a -> a Source #

Determine entropy for list of numbers

`>>>`

2.770950594454668`entropy [0.3, 0.3, 0.05, 0.05, 0.05, 0.05, 0.05, 0.05, 0.05, 0.05]`

`>>>`

1.9593816735406657`entropy [789, 621, 109, 65, 45, 30, 27, 15, 12, 9]`

ratio :: (Foldable t, RealFrac a1, Fractional a, Floating a1) => t a1 -> a Source #

entropy divided by controlLimit.

`>>>`

1.0`ratio [0.3, 0.3, 0.05, 0.05, 0.05, 0.05, 0.05, 0.05, 0.05, 0.05]`

pareto :: (Foldable t, RealFrac a, Floating a) => t a -> Bool Source #

Returns True if pareto distribution is present otherwise False.

`>>>`

True`pareto [0.3, 0.3, 0.05, 0.05, 0.05, 0.05, 0.05, 0.05, 0.05, 0.05]`

causeEffect :: (RealFrac a1, Fractional b, Fractional a, Enum a) => [a1] -> [(a, b)] Source #

Return list of cause-effect pairs.

`>>>`

[(0.1,0.458),(0.2,0.819),(0.3,0.882),(0.4,0.92),(0.5,0.946),(0.6,0.963),(0.7,0.979),(0.8,0.988),(0.9,0.995),(1.0,1.0)]`causeEffect [789, 621, 109, 65, 45, 30, 27, 15, 12, 9]`

causesMaxConcentration :: [Float] -> Float Source #

Which causes have the maximum concentration (rank * value)?

`>>>`

0.2`causesMaxConcentration [789, 621, 109, 65, 45, 30, 27, 15, 12, 9]`