Module Ppl.Primitive
Module defining a type for primitive distributions
type 'a support
=
|
DiscreteFinite of 'a list
A list of valid values
|
DiscreteInfinite
discrete dist with infinite support e.g. poisson
|
ContinuousFinite of ('a * 'a) list
set of endpoints
|
ContinuousInfinite
continuous dist with an infinite support e.g.
|
Merged of 'a support * 'a support
combination of any of the above
The type of supports - the values with a distribution can take
module type PRIM_DIST = sig ... end
The signature for new primitive distributions
New Distributions
Predefined Distributions
val binomial : int -> float -> int t
val categorical : ('a * float) list -> 'a t
val normal : float -> float -> float t
val discrete_uniform : 'a list -> 'a t
val beta : float -> float -> float t
val gamma : float -> float -> float t
val poisson : float -> int t
val continuous_uniform : float -> float -> float t