boax.core.distributions module#

Implements common probability distributions.

Distributions#

Beta Distribution#

class boax.core.distributions.beta.Beta(a: Array | ndarray | bool | number, b: Array | ndarray | bool | number)#

A tuple describing the two shape parameters of the beta distribution.

a#

The alpha parameter.

b#

The beta parameter.

beta([a, b])

Smart constructor for the beta distribution.

pdf(beta, values)

Probability density function.

cdf(beta, values)

Cumulative distribution function.

sf(beta, values)

Survival function.

logpdf(beta, values)

Log probability density function.

logcdf(beta, values)

Log cumulative distribution function.

logsf(beta, values)

Log survival function.

Gamma Distribution#

class boax.core.distributions.gamma.Gamma(a: Array | ndarray | bool | number, b: Array | ndarray | bool | number)#

A tuple describing the shape and rate parameters of the gamma distribution.

a#

The shape parameter.

b#

The rate parameter.

gamma(a[, b])

Smart constructor for the gamma distribution.

pdf(gamma, values)

Probability density function.

cdf(gamma, values)

Cumulative distribution function.

sf(gamma, values)

Survival function.

logpdf(gamma, values)

Log probability density function.

logcdf(gamma, values)

Log cumulative distribution function.

logsf(gamma, values)

Log survival function.

Multivariate Normal Distribution#

class boax.core.distributions.multivariate_normal.MultivariateNormal(mean: Array | ndarray | bool | number, cov: Array | ndarray | bool | number)#

A tuple describing the two parameters of the multivariate normal distribution.

mean#

The mean vector parameter.

cov#

The covariance matrix parameter.

multivariate_normal([mean, cov])

Smart constructor for the multivariate normal distribution.

pdf(mvn, values)

Probability density function.

logpdf(mvn, values)

Log probability density function.

Normal Distribution#

class boax.core.distributions.normal.Normal(loc: Array | ndarray | bool | number, scale: Array | ndarray | bool | number)#

A tuple describing the two parameters of the normal distribution.

loc#

The location parameter.

scale#

The scale parameter.

normal([loc, scale])

Smart constructor for the normal distribution.

pdf(normal, x)

Probability density function.

cdf(normal, x)

Cumulative distribution function.

sf(normal, x)

Survival function.

logpdf(normal, x)

Log probability density function.

logcdf(normal, x)

Log cumulative distribution function.

logsf(normal, x)

Log survival function.

Poisson Distribution#

class boax.core.distributions.poisson.Poisson(mu: Array | ndarray | bool | number)#

A tuple describing the rate parameter of the poisson distribution.

mu#

The rate parameter.

poisson(mu)

Smart constructor for the poisson distribution.

pmf(poisson, values)

Probability mass function.

cdf(poisson, values)

Cumulative distribution function.

logpmf(poisson, values)

Log probability density function.

Uniform Distribution#

class boax.core.distributions.uniform.Uniform(a: Array | ndarray | bool | number, b: Array | ndarray | bool | number)#

A tuple describing the two parameters of the uniform distribution.

a#

The minium value parameter.

b#

The maximum value parameter.

uniform([a, b])

Smart constructor for the uniform distribution.

pdf(uniform, values)

Probability density function.

logpdf(uniform, values)

Log probability density function.