A Boltzmann (Truncated Discrete Exponential) random variable.
As an instance of the rv_discrete class, boltzmann object inherits from it
a collection of generic methods (see below for the full list),
and completes them with details specific for this particular distribution.
Methods
rvs(lambda_, N, loc=0, size=1, random_state=None)
Random variates.
pmf(k, lambda_, N, loc=0)
Probability mass function.
logpmf(k, lambda_, N, loc=0)
Log of the probability mass function.
cdf(k, lambda_, N, loc=0)
Cumulative distribution function.
logcdf(k, lambda_, N, loc=0)
Log of the cumulative distribution function.
sf(k, lambda_, N, loc=0)
Survival function (also defined as 1-cdf, but sf is sometimes more accurate).
logsf(k, lambda_, N, loc=0)
Log of the survival function.
ppf(q, lambda_, N, loc=0)
Percent point function (inverse of cdf — percentiles).
boltzmann takes \(\lambda > 0\) and \(N > 0\) as shape parameters.
The probability mass function above is defined in the "standardized" form.
To shift distribution use the loc parameter.
Specifically, boltzmann.pmf(k,lambda_,N,loc) is identically
equivalent to boltzmann.pmf(k-loc,lambda_,N).
Alternatively, the distribution object can be called (as a function)
to fix the shape and location. This returns a "frozen" RV object holding
the given parameters fixed.
Freeze the distribution and display the frozen pmf: