pymc.Uniform#
- class pymc.Uniform(name, *args, rng=None, dims=None, initval=None, observed=None, total_size=None, transform=UNSET, default_transform=UNSET, **kwargs)[source]#
Continuous uniform distribution.
The probability density function (pdf) of this distribution is:
\[f(x \mid lower, upper) = \frac{1}{upper - lower}\](
Source code,png,hires.png,pdf)
Support
\(x \in [lower, upper]\)
Mean
\(\dfrac{lower + upper}{2}\)
Variance
\(\dfrac{(upper - lower)^2}{12}\)
- Parameters:
- lowertensor_like of
float, optional Lower bound of the distribution. Defaults to 0.
- uppertensor_like of
float, optional Upper bound of the distribution. Defaults to 1.
- lowertensor_like of
- Returns:
TensorVariableA random variable representing the Uniform distribution.
Methods
Uniform.dist([lower, upper])Create a tensor variable corresponding to the cls distribution.