probability-0.2.7: Probabilistic Functional Programming

Safe HaskellSafe
LanguageHaskell98

Numeric.Probability.Percentage

Contents

Description

Number type based on Float with formatting in percents.

Synopsis

Probabilities

newtype T Source #

Constructors

Cons Float 
Instances
Eq T Source # 
Instance details

Defined in Numeric.Probability.Percentage

Methods

(==) :: T -> T -> Bool #

(/=) :: T -> T -> Bool #

Floating T Source # 
Instance details

Defined in Numeric.Probability.Percentage

Methods

pi :: 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 #

Fractional T Source # 
Instance details

Defined in Numeric.Probability.Percentage

Methods

(/) :: T -> T -> T #

recip :: T -> T #

fromRational :: Rational -> T #

Num T Source # 
Instance details

Defined in Numeric.Probability.Percentage

Methods

(+) :: T -> T -> T #

(-) :: T -> T -> T #

(*) :: T -> T -> T #

negate :: T -> T #

abs :: T -> T #

signum :: T -> T #

fromInteger :: Integer -> T #

Ord T Source # 
Instance details

Defined in Numeric.Probability.Percentage

Methods

compare :: T -> T -> Ordering #

(<) :: T -> T -> Bool #

(<=) :: T -> T -> Bool #

(>) :: T -> T -> Bool #

(>=) :: T -> T -> Bool #

max :: T -> T -> T #

min :: T -> T -> T #

Show T Source # 
Instance details

Defined in Numeric.Probability.Percentage

Methods

showsPrec :: Int -> T -> ShowS #

show :: T -> String #

showList :: [T] -> ShowS #

Random T Source # 
Instance details

Defined in Numeric.Probability.Percentage

Methods

randomR :: 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] #

ToFloat T Source # 
Instance details

Defined in Numeric.Probability.Expectation

Methods

toFloat :: T -> Float Source #

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 #