Safe Haskell | None |
---|
- class Distribution dist sample prob | dist -> sample where
- pdf :: dist -> sample -> prob
- cdf :: dist -> sample -> prob
- cdfInverse :: dist -> prob -> sample
- module Data.Number.LogFloat
Documentation
class Distribution dist sample prob | dist -> sample whereSource
We use the same class for both discrete and continuous distributions. Unfortunately, we cannot use the type classes from the statistics
package because we require more generalilty.
pdf :: dist -> sample -> probSource
cdf :: dist -> sample -> probSource
cdfInverse :: dist -> prob -> sampleSource
Distribution (Gaussian Double) Double Double | |
(Ord label, Ord prob, Floating prob, Random prob) => Distribution (Categorical label prob) label prob |
module Data.Number.LogFloat