probability-0.2.5.2: Probabilistic Functional Programming

Numeric.Probability.Percentage

Contents

Description

Number type based on Float with formatting in percents.

Synopsis

## Probabilities

newtype T Source #

Constructors

 Cons Float
Instances
 Source # Instance detailsDefined in Numeric.Probability.Percentage Methods(==) :: T -> T -> Bool #(/=) :: T -> T -> Bool # Source # Instance detailsDefined in Numeric.Probability.Percentage Methodspi :: T #exp :: T -> T #log :: T -> T #sqrt :: T -> T #(**) :: T -> T -> T #logBase :: T -> T -> T #sin :: T -> T #cos :: T -> T #tan :: T -> T #asin :: T -> T #acos :: T -> T #atan :: T -> T #sinh :: T -> T #cosh :: T -> T #tanh :: T -> T #asinh :: T -> T #acosh :: T -> T #atanh :: T -> T #log1p :: T -> T #expm1 :: T -> T #log1pexp :: T -> T #log1mexp :: T -> T # Source # Instance detailsDefined in Numeric.Probability.Percentage Methods(/) :: T -> T -> T #recip :: T -> T # Source # Instance detailsDefined in Numeric.Probability.Percentage Methods(+) :: T -> T -> T #(-) :: T -> T -> T #(*) :: T -> T -> T #negate :: T -> T #abs :: T -> T #signum :: T -> T # Source # Instance detailsDefined in Numeric.Probability.Percentage Methodscompare :: T -> T -> Ordering #(<) :: T -> T -> Bool #(<=) :: T -> T -> Bool #(>) :: T -> T -> Bool #(>=) :: T -> T -> Bool #max :: T -> T -> T #min :: T -> T -> T # Source # Instance detailsDefined in Numeric.Probability.Percentage MethodsshowsPrec :: Int -> T -> ShowS #show :: T -> String #showList :: [T] -> ShowS # Source # Instance detailsDefined in Numeric.Probability.Percentage MethodsrandomR :: RandomGen g => (T, T) -> g -> (T, g) #random :: RandomGen g => g -> (T, g) #randomRs :: RandomGen g => (T, T) -> g -> [T] #randoms :: RandomGen g => g -> [T] #randomRIO :: (T, T) -> IO T # Source # Instance detailsDefined in Numeric.Probability.Expectation Methods

showPfix :: (RealFrac prob, Show prob) => Int -> prob -> String Source #

roundRel :: RealFrac a => Int -> a -> a Source #

Deprecated: was used to implemented showPfix, but is no longer needed for this purpose, and should not be exported anyway, and does not contribute to a safe way to format fixed point values, because the rounded value may not be accurate

(//) :: (Ord a, Show a) => Dist a -> Int -> IO () infix 0 Source #

Print distribution as table with configurable precision.

(//*) :: (Ord a, Show a) => Dist a -> (Int, Int) -> IO () Source #

liftP :: (Float -> Float) -> T -> T Source #

liftP2 :: (Float -> Float -> Float) -> T -> T -> T Source #

type Dist a = T T a Source #

type Spread a = [a] -> Dist a Source #

type RDist a = T (Dist a) Source #

type Trans a = a -> Dist a Source #

type Space a = Trace (Dist a) Source #

type Expand a = a -> Space a Source #

type RTrans a = a -> RDist a Source #

type RSpace a = T (Space a) Source #

type RExpand a = a -> RSpace a Source #