As an instance of the rv_discrete class, planck 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_, loc=0, size=1, random_state=None)
Random variates.
pmf(k, lambda_, loc=0)
Probability mass function.
logpmf(k, lambda_, loc=0)
Log of the probability mass function.
cdf(k, lambda_, loc=0)
Cumulative distribution function.
logcdf(k, lambda_, loc=0)
Log of the cumulative distribution function.
sf(k, lambda_, loc=0)
Survival function (also defined as 1-cdf, but sf is sometimes more accurate).
logsf(k, lambda_, loc=0)
Log of the survival function.
ppf(q, lambda_, loc=0)
Percent point function (inverse of cdf — percentiles).
planck takes \(\lambda\) as shape parameter. The Planck distribution
can be written as a geometric distribution (geom) with
\(p = 1 - \exp(-\lambda)\) shifted by loc=-1.
The probability mass function above is defined in the "standardized" form.
To shift distribution use the loc parameter.
Specifically, planck.pmf(k,lambda_,loc) is identically
equivalent to planck.pmf(k-loc,lambda_).
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: