Appendix: Selected scipy.stats Discrete Random Variables
Here is the list of scipy.stats discrete random variables.
Num. args Min range Max range Parameters
Distribution
bernoulli 1 0 1 'p'
dlaplace 1 -inf inf 'a'
geom 1 1 inf 'p'
logser 1 1 inf 'p'
planck 1 0 inf 'lambda\_'
poisson 1 0 inf 'mu'
yulesimon 1 1 inf 'alpha'
zipf 1 1 inf 'a'
binom 2 0 inf 'n' and 'p'
boltzmann 2 0 inf 'lambda\_' and 'N'
nbinom 2 0 inf 'n' and 'p'
randint 2 0 inf 'low' and 'high'
skellam 2 -inf inf 'mu1' and 'mu2'
zipfian 2 1 inf 'a' and 'n'
betabinom 3 0 inf 'n', 'a', and 'b'
hypergeom 3 0 inf 'M', 'n', and 'N'
nhypergeom 3 0 inf 'M', 'n', and 'r'
nchypergeom_fisher 4 0 inf 'M', 'n', 'N', and 'odds'
nchypergeom_wallenius 4 0 inf 'M', 'n', 'N', and 'odds'
bernoulliBernoulli (help). The probability mass function for bernoulli is:\[\begin{split}f(k) = \begin{cases}1-p &\text{if } k = 0\\ p &\text{if } k = 1\end{cases}\end{split}\]for \(k\) in \(\{0, 1\}\), \(0 \leq p \leq 1\)
bernoulli takes \(p\) as shape parameter, where \(p\) is the probability of a single success and \(1-p\) is the probability of a single failure.
The probability mass function above is defined in the “standardized” form. To shift distribution use the
locparameter. Specifically,bernoulli.pmf(k, p, loc)is identically equivalent tobernoulli.pmf(k - loc, p).
betabinomBetabinom (help). The beta-binomial distribution is a binomial distribution with aprobability of success p that follows a beta distribution.
The probability mass function for betabinom is:
\[f(k) = \binom{n}{k} \frac{B(k + a, n - k + b)}{B(a, b)}\]for \(k \in \{0, 1, \dots, n\}\), \(n \geq 0\), \(a > 0\), \(b > 0\), where \(B(a, b)\) is the beta function.
betabinom takes \(n\), \(a\), and \(b\) as shape parameters.
binomBinom (help). The probability mass function for binom is:\[f(k) = \binom{n}{k} p^k (1-p)^{n-k}\]for \(k \in \{0, 1, \dots, n\}\), \(0 \leq p \leq 1\)
binom takes \(n\) and \(p\) as shape parameters, where \(p\) is the probability of a single success and \(1-p\) is the probability of a single failure.
boltzmannBoltzmann (help). The probability mass function for boltzmann is:\[f(k) = (1-\exp(-\lambda)) \exp(-\lambda k) / (1-\exp(-\lambda N))\]for \(k = 0,..., N-1\).
boltzmann takes \(\lambda > 0\) and \(N > 0\) as shape parameters.
geomGeom (help). The probability mass function for geom is:\[f(k) = (1-p)^{k-1} p\]for \(k \ge 1\), \(0 < p \leq 1\)
geom takes \(p\) as shape parameter, where \(p\) is the probability of a single success and \(1-p\) is the probability of a single failure.
logserLogser (help). The probability mass function for logser is:\[f(k) = - \frac{p^k}{k \log(1-p)}\]for \(k \ge 1\), \(0 < p < 1\)
logser takes \(p\) as shape parameter, where \(p\) is the probability of a single success and \(1-p\) is the probability of a single failure.
nbinomNbinom (help). Negative binomial distribution describes a sequence of i.i.d. Bernoullitrials, repeated until a predefined, non-random number of successes occurs.
The probability mass function of the number of failures for nbinom is:
\[f(k) = \binom{k+n-1}{n-1} p^n (1-p)^k\]for \(k \ge 0\), \(0 < p \leq 1\)
nbinom takes \(n\) and \(p\) as shape parameters where n is the number of successes, \(p\) is the probability of a single success, and \(1-p\) is the probability of a single failure.
Another common parameterization of the negative binomial distribution is in terms of the mean number of failures \(\mu\) to achieve \(n\) successes. The mean \(\mu\) is related to the probability of success as
\[p = \frac{n}{n + \mu}\]The number of successes \(n\) may also be specified in terms of a “dispersion”, “heterogeneity”, or “aggregation” parameter \(\alpha\), which relates the mean \(\mu\) to the variance \(\sigma^2\), e.g. \(\sigma^2 = \mu + \alpha \mu^2\). Regardless of the convention used for \(\alpha\),
\[\begin{split}p &= \frac{\mu}{\sigma^2} \\ n &= \frac{\mu^2}{\sigma^2 - \mu}\end{split}\]
planckPlanck (help). The probability mass function for planck is:\[f(k) = (1-\exp(-\lambda)) \exp(-\lambda k)\]for \(k \ge 0\) and \(\lambda > 0\).
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.
poissonPoisson (help). The probability mass function for poisson is:\[f(k) = \exp(-\mu) \frac{\mu^k}{k!}\]for \(k \ge 0\).
poisson takes \(\mu \geq 0\) as shape parameter. When \(\mu = 0\), the
pmfmethod returns1.0at quantile \(k = 0\).
randintRandint (help). The probability mass function for randint is:\[f(k) = \frac{1}{\texttt{high} - \texttt{low}}\]for \(k \in \{\texttt{low}, \dots, \texttt{high} - 1\}\).
randint takes \(\texttt{low}\) and \(\texttt{high}\) as shape parameters.
Appendix: scipy.stats Continuous Random Variables
The information below was extracted from the scipy help for continuous distributions. The basic list can be created by introspection—wonderful Python!
In [1]: import scipy.stats as ss
In [2]: import pandas as pd
In [3]: ans = []
In [4]: for k in dir(ss):
...: ob = getattr(ss, k)
...: if str(type(ob)).find('continuous_distns') > 0:
...: try:
...: fz = ob()
...: except TypeError as e:
...: ee = e
...: ans.append([k, str(e), -1, ob.a, ob.b])
...: else:
...: ans.append([k, 'no args fine', 0, ob.a, ob.b])
...:
In [5]: df = pd.DataFrame(ans, columns=['dist', 'm', 'args', 'a', 'b'])
In [6]: for i in range(1,5):
...: df.loc[df.m.str.find(f'{i} required')>=0, 'args'] = i
...:
In [7]: df = df.sort_values(['args', 'dist'])
In [8]: df['params'] = ''
In [9]: df.loc[df.args > 0, 'params'] = df.loc[df.args > 0, 'm'].str.split(':').str[1]
In [10]: df = df.drop(columns='m')
In [11]: print(df.rename(columns={'dist': 'Distribution', 'args': 'Num. args',
....: 'a': 'Min range' , 'b': 'Max range', 'params': 'Parameters'}).\
....: set_index('Distribution').to_string(float_format=lambda x: f'{x:.4g}'))
....:
Num. args Min range Max range Parameters
Distribution
anglit 0 -0.7854 0.7854
arcsine 0 0 1
cauchy 0 -inf inf
cosine 0 -3.142 3.142
expon 0 0 inf
gibrat 0 0 inf
gumbel_l 0 -inf inf
gumbel_r 0 -inf inf
halfcauchy 0 0 inf
halflogistic 0 0 inf
halfnorm 0 0 inf
hypsecant 0 -inf inf
kstwobign 0 0 inf
laplace 0 -inf inf
levy 0 0 inf
levy_l 0 -inf 0
logistic 0 -inf inf
maxwell 0 0 inf
moyal 0 -inf inf
norm 0 -inf inf
rayleigh 0 0 inf
semicircular 0 -1 1
uniform 0 0 1
wald 0 0 inf
alpha 1 0 inf 'a'
argus 1 0 1 'chi'
bradford 1 0 1 'c'
chi 1 0 inf 'df'
chi2 1 0 inf 'df'
dgamma 1 -inf inf 'a'
dweibull 1 -inf inf 'c'
erlang 1 0 inf 'a'
exponnorm 1 -inf inf 'K'
exponpow 1 0 inf 'b'
fatiguelife 1 0 inf 'c'
fisk 1 0 inf 'c'
foldcauchy 1 0 inf 'c'
foldnorm 1 0 inf 'c'
gamma 1 0 inf 'a'
genextreme 1 -inf inf 'c'
genhalflogistic 1 0 inf 'c'
genlogistic 1 -inf inf 'c'
gennorm 1 -inf inf 'beta'
genpareto 1 0 inf 'c'
gompertz 1 0 inf 'c'
halfgennorm 1 0 inf 'beta'
invgamma 1 0 inf 'a'
invgauss 1 0 inf 'mu'
invweibull 1 0 inf 'c'
kappa3 1 0 inf 'a'
ksone 1 0 1 'n'
kstwo 1 0 1 'n'
laplace_asymmetric 1 -inf inf 'kappa'
loggamma 1 -inf inf 'c'
loglaplace 1 0 inf 'c'
lognorm 1 0 inf 's'
lomax 1 0 inf 'c'
nakagami 1 0 inf 'nu'
pareto 1 1 inf 'b'
pearson3 1 -inf inf 'skew'
powerlaw 1 0 1 'a'
powernorm 1 -inf inf 'c'
rdist 1 -1 1 'c'
recipinvgauss 1 0 inf 'mu'
rel_breitwigner 1 0 inf 'rho'
rice 1 0 inf 'b'
skewcauchy 1 -inf inf 'a'
skewnorm 1 -inf inf 'a'
t 1 -inf inf 'df'
triang 1 0 1 'c'
truncexpon 1 0 inf 'b'
tukeylambda 1 -inf inf 'lam'
vonmises 1 -inf inf 'kappa'
vonmises_line 1 -3.142 3.142 'kappa'
weibull_max 1 -inf 0 'c'
weibull_min 1 0 inf 'c'
wrapcauchy 1 0 6.283 'c'
beta 2 0 1 'a' and 'b'
betaprime 2 0 inf 'a' and 'b'
burr 2 0 inf 'c' and 'd'
burr12 2 0 inf 'c' and 'd'
crystalball 2 -inf inf 'beta' and 'm'
exponweib 2 0 inf 'a' and 'c'
f 2 0 inf 'dfn' and 'dfd'
gengamma 2 0 inf 'a' and 'c'
geninvgauss 2 0 inf 'p' and 'b'
jf_skew_t 2 -inf inf 'a' and 'b'
johnsonsb 2 0 1 'a' and 'b'
johnsonsu 2 -inf inf 'a' and 'b'
kappa4 2 -inf inf 'h' and 'k'
loguniform 2 -inf inf 'a' and 'b'
mielke 2 0 inf 'k' and 's'
nct 2 -inf inf 'df' and 'nc'
ncx2 2 0 inf 'df' and 'nc'
norminvgauss 2 -inf inf 'a' and 'b'
powerlognorm 2 0 inf 'c' and 's'
reciprocal 2 -inf inf 'a' and 'b'
studentized_range 2 0 inf 'k' and 'df'
trapezoid 2 0 1 'c' and 'd'
trapz 2 0 1 'c' and 'd'
truncnorm 2 -inf inf 'a' and 'b'
truncpareto 2 1 inf 'b' and 'c'
genexpon 3 0 inf 'a', 'b', and 'c'
genhyperbolic 3 -inf inf 'p', 'a', and 'b'
ncf 3 0 inf 'dfn', 'dfd', and 'nc'
truncweibull_min 3 -inf inf 'c', 'a', and 'b'
gausshyper 4 0 1 'a', 'b', 'c', and 'z'
alphaAlpha (help). The probability density function for alpha is:\[f(x, a) = \frac{1}{x^2 \Phi(a) \sqrt{2\pi}} * \exp(-\frac{1}{2} (a-1/x)^2)\]where \(\Phi\) is the normal CDF, \(x > 0\), and \(a > 0\).
alpha takes
aas a shape parameter.
anglitAnglit (help). The probability density function for anglit is:\[f(x) = \sin(2x + \pi/2) = \cos(2x)\]for \(-\pi/4 \le x \le \pi/4\).
arcsineArcsine (help). The probability density function for arcsine is:\[f(x) = \frac{1}{\pi \sqrt{x (1-x)}}\]for \(0 < x < 1\).
argusArgus (help). The probability density function for argus is:\[f(x, \chi) = \frac{\chi^3}{\sqrt{2\pi} \Psi(\chi)} x \sqrt{1-x^2} \exp(-\chi^2 (1 - x^2)/2)\]for \(0 < x < 1\) and \(\chi > 0\), where
\[\Psi(\chi) = \Phi(\chi) - \chi \phi(\chi) - 1/2\]with \(\Phi\) and \(\phi\) being the CDF and PDF of a standard normal distribution, respectively.
argus takes \(\chi\) as shape a parameter.
betaBeta (help). The probability density function for beta is:\[f(x, a, b) = \frac{\Gamma(a+b) x^{a-1} (1-x)^{b-1}} {\Gamma(a) \Gamma(b)}\]for \(0 <= x <= 1\), \(a > 0\), \(b > 0\), where \(\Gamma\) is the gamma function (scipy.special.gamma).
beta takes \(a\) and \(b\) as shape parameters.
betaprimeBeta Prime (help). The probability density function for betaprime is:\[f(x, a, b) = \frac{x^{a-1} (1+x)^{-a-b}}{\beta(a, b)}\]for \(x >= 0\), \(a > 0\), \(b > 0\), where \(\beta(a, b)\) is the beta function (see scipy.special.beta).
betaprime takes
aandbas shape parameters.
bradfordBradford (help). The probability density function for bradford is:\[f(x, c) = \frac{c}{\log(1+c) (1+cx)}\]for \(0 <= x <= 1\) and \(c > 0\).
bradford takes
cas a shape parameter for \(c\).
burrBurr (Type III) (help). The probability density function for burr is:\[f(x, c, d) = c d x^{-c - 1} / (1 + x^{-c})^{d + 1}\]for \(x >= 0\) and \(c, d > 0\).
burr takes \(c\) and \(d\) as shape parameters.
This is the PDF corresponding to the third CDF given in Burr’s list; specifically, it is equation (11) in Burr’s paper. The distribution is also commonly referred to as the Dagum distribution. If the parameter \(c < 1\) then the mean of the distribution does not exist and if \(c < 2\) the variance does not exist. The PDF is finite at the left endpoint \(x = 0\) if \(c * d >= 1\).
burr12Burr (Type XII) (help). The probability density function for burr is:\[f(x, c, d) = c d x^{c-1} / (1 + x^c)^{d + 1}\]for \(x >= 0\) and \(c, d > 0\).
burr12 takes
canddas shape parameters for \(c\) and \(d\).This is the PDF corresponding to the twelfth CDF given in Burr’s list; specifically, it is equation (20) in Burr’s paper.
cauchyCauchy (help). The probability density function for cauchy is\[f(x) = \frac{1}{\pi (1 + x^2)}\]for a real number \(x\).
chiChi (help). The probability density function for chi is:\[f(x, k) = \frac{1}{2^{k/2-1} \Gamma \left( k/2 \right)} x^{k-1} \exp \left( -x^2/2 \right)\]for \(x >= 0\) and \(k > 0\) (degrees of freedom, denoted
dfin the implementation). \(\Gamma\) is the gamma function (scipy.special.gamma).Special cases of chi are:
chi(1, loc, scale)is equivalent to halfnormchi(2, 0, scale)is equivalent to rayleighchi(3, 0, scale)is equivalent to maxwell
chi takes
dfas a shape parameter.
chi2Chi-squared (help). The probability density function for chi2 is:\[f(x, k) = \frac{1}{2^{k/2} \Gamma \left( k/2 \right)} x^{k/2-1} \exp \left( -x/2 \right)\]for \(x > 0\) and \(k > 0\) (degrees of freedom, denoted
dfin the implementation).chi2 takes
dfas a shape parameter.The chi-squared distribution is a special case of the gamma distribution, with gamma parameters
a = df/2,loc = 0andscale = 2.
cosineCosine (help). The cosine distribution is an approximation to the normal distribution. The probability density function for cosine is:\[f(x) = \frac{1}{2\pi} (1+\cos(x))\]for \(-\pi \le x \le \pi\).
crystalballCrystalball (help). The probability density function for crystalball is:\[\begin{split}f(x, \beta, m) = \begin{cases} N \exp(-x^2 / 2), &\text{for } x > -\beta\\ N A (B - x)^{-m} &\text{for } x \le -\beta \end{cases}\end{split}\]where \(A = (m / |\beta|)^m \exp(-\beta^2 / 2)\), \(B = m/|\beta| - |\beta|\) and \(N\) is a normalisation constant.
crystalball takes \(\beta > 0\) and \(m > 1\) as shape parameters. \(\beta\) defines the point where the pdf changes from a power-law to a Gaussian distribution. \(m\) is the power of the power-law tail.
dgammaDouble Gamma (help). The probability density function for dgamma is:\[f(x, a) = \frac{1}{2\Gamma(a)} |x|^{a-1} \exp(-|x|)\]for a real number \(x\) and \(a > 0\). \(\Gamma\) is the gamma function (scipy.special.gamma).
dgamma takes
aas a shape parameter for \(a\).
dweibullDouble Weibull (help). The probability density function for dweibull is given by\[f(x, c) = c / 2 |x|^{c-1} \exp(-|x|^c)\]for a real number \(x\) and \(c > 0\).
dweibull takes
cas a shape parameter for \(c\).
erlangErlang (help). The Erlang distribution is a special case of the Gamma distribution, with the shape parameter a an integer. Note that this restriction is not enforced by erlang. It will, however, generate a warning the first time a non-integer value is used for the shape parameter.Refer to gamma for examples.
exponExponential (help). The probability density function for expon is:\[f(x) = \exp(-x)\]for \(x \ge 0\).
exponnormExponentially Modified Normal (help). The probability density function for exponnorm is:\[f(x, K) = \frac{1}{2K} \exp\left(\frac{1}{2 K^2} - x / K \right) \text{erfc}\left(-\frac{x - 1/K}{\sqrt{2}}\right)\]where \(x\) is a real number and \(K > 0\).
It can be thought of as the sum of a standard normal random variable and an independent exponentially distributed random variable with rate
1/K.
exponweibExponentiated Weibull (help). The probability density function for exponweib is:\[f(x, a, c) = a c [1-\exp(-x^c)]^{a-1} \exp(-x^c) x^{c-1}\]and its cumulative distribution function is:
\[F(x, a, c) = [1-\exp(-x^c)]^a\]for \(x > 0\), \(a > 0\), \(c > 0\).
exponweib takes \(a\) and \(c\) as shape parameters:
\(a\) is the exponentiation parameter, with the special case \(a=1\) corresponding to the (non-exponentiated) Weibull distribution weibull_min.
\(c\) is the shape parameter of the non-exponentiated Weibull law.
exponpowExponential Power (help). The probability density function for exponpow is:\[f(x, b) = b x^{b-1} \exp(1 + x^b - \exp(x^b))\]for \(x \ge 0\), \(b > 0\). Note that this is a different distribution from the exponential power distribution that is also known under the names “generalized normal” or “generalized Gaussian”.
exponpow takes
bas a shape parameter for \(b\).
fF (Snecdor F) (help). The probability density function for f is:\[f(x, df_1, df_2) = \frac{df_2^{df_2/2} df_1^{df_1/2} x^{df_1 / 2-1}} {(df_2+df_1 x)^{(df_1+df_2)/2} B(df_1/2, df_2/2)}\]for \(x > 0\).
f takes
dfnanddfdas shape parameters.
fatiguelifeFatigue Life (Birnbaum-Saunders) (help). The probability density function for fatiguelife is:\[f(x, c) = \frac{x+1}{2c\sqrt{2\pi x^3}} \exp(-\frac{(x-1)^2}{2x c^2})\]for \(x >= 0\) and \(c > 0\).
fatiguelife takes
cas a shape parameter for \(c\).
fiskFisk (help). The probability density function for fisk is:\[f(x, c) = c x^{-c-1} (1 + x^{-c})^{-2}\]for \(x >= 0\) and \(c > 0\).
fisk takes
cas a shape parameter for \(c\).fisk is a special case of burr or burr12 with
d=1.
foldcauchyFolded Cauchy (help). The probability density function for foldcauchy is:\[f(x, c) = \frac{1}{\pi (1+(x-c)^2)} + \frac{1}{\pi (1+(x+c)^2)}\]for \(x \ge 0\).
foldcauchy takes
cas a shape parameter for \(c\).
foldnormFolded Normal (help). The probability density function for foldnorm is:\[f(x, c) = \sqrt{2/\pi} cosh(c x) \exp(-\frac{x^2+c^2}{2})\]for \(c \ge 0\).
foldnorm takes
cas a shape parameter for \(c\).
genlogisticGeneralized Logistic (help). The probability density function for genlogistic is:\[f(x, c) = c \frac{\exp(-x)} {(1 + \exp(-x))^{c+1}}\]for \(x >= 0\), \(c > 0\).
genlogistic takes
cas a shape parameter for \(c\).
gennormGeneralized normal (help). The probability density function for gennorm is:\[f(x, \beta) = \frac{\beta}{2 \Gamma(1/\beta)} \exp(-|x|^\beta)\]\(\Gamma\) is the gamma function (scipy.special.gamma).
gennorm takes
betaas a shape parameter for \(\beta\). For \(\beta = 1\), it is identical to a Laplace distribution. For \(\beta = 2\), it is identical to a normal distribution (withscale=1/sqrt(2)).
genparetoGeneralized Pareto (help). The probability density function for genpareto is:\[f(x, c) = (1 + c x)^{-1 - 1/c}\]defined for \(x \ge 0\) if \(c \ge 0\), and for \(0 \le x \le -1/c\) if \(c < 0\).
genpareto takes
cas a shape parameter for \(c\).For \(c=0\), genpareto reduces to the exponential distribution, expon:
\[f(x, 0) = \exp(-x)\]For \(c=-1\), genpareto is uniform on
[0, 1]:\[f(x, -1) = 1\]
genexponGeneralized Exponential (help). The probability density function for genexpon is:\[f(x, a, b, c) = (a + b (1 - \exp(-c x))) \exp(-a x - b x + \frac{b}{c} (1-\exp(-c x)))\]for \(x \ge 0\), \(a, b, c > 0\).
genexpon takes \(a\), \(b\) and \(c\) as shape parameters.
genextremeGeneralized Extreme Value (help). For \(c=0\), genextreme is equal to gumbel_r. The probability density function for genextreme is:\[\begin{split}f(x, c) = \begin{cases} \exp(-\exp(-x)) \exp(-x) &\text{for } c = 0\\ \exp(-(1-c x)^{1/c}) (1-c x)^{1/c-1} &\text{for } x \le 1/c, c > 0 \end{cases}\end{split}\]Note that several sources and software packages use the opposite convention for the sign of the shape parameter \(c\).
genextreme takes
cas a shape parameter for \(c\).
gausshyperGauss Hypergeometric (help). The probability density function for gausshyper is:\[f(x, a, b, c, z) = C x^{a-1} (1-x)^{b-1} (1+zx)^{-c}\]for \(0 \le x \le 1\), \(a > 0\), \(b > 0\), \(z > -1\), and \(C = \frac{1}{B(a, b) F[2, 1](c, a; a+b; -z)}\). \(F[2, 1]\) is the Gauss hypergeometric function scipy.special.hyp2f1.
gausshyper takes \(a\), \(b\), \(c\) and \(z\) as shape parameters.
gammaGamma (help). The probability density function for gamma is:\[f(x, a) = \frac{x^{a-1} e^{-x}}{\Gamma(a)}\]for \(x \ge 0\), \(a > 0\). Here \(\Gamma(a)\) refers to the gamma function.
gamma takes
aas a shape parameter for \(a\).When \(a\) is an integer, gamma reduces to the Erlang distribution, and when \(a=1\) to the exponential distribution.
Gamma distributions are sometimes parameterized with two variables, with a probability density function of:
\[f(x, \alpha, \beta) = \frac{\beta^\alpha x^{\alpha - 1} e^{-\beta x }}{\Gamma(\alpha)}\]Note that this parameterization is equivalent to the above, with
scale = 1 / beta.
gengammaGeneralized gamma (help). The probability density function for gengamma is:\[f(x, a, c) = \frac{|c| x^{c a-1} \exp(-x^c)}{\Gamma(a)}\]for \(x \ge 0\), \(a > 0\), and \(c \ne 0\). \(\Gamma\) is the gamma function (scipy.special.gamma).
gengamma takes \(a\) and \(c\) as shape parameters.
genhalflogisticGeneralized Half Logistic (help). The probability density function for genhalflogistic is:\[f(x, c) = \frac{2 (1 - c x)^{1/(c-1)}}{[1 + (1 - c x)^{1/c}]^2}\]for \(0 \le x \le 1/c\), and \(c > 0\).
genhalflogistic takes
cas a shape parameter for \(c\).
genhyperbolicGeneralized Hyperbolic (help). The probability density function for genhyperbolic is:\[f(x, p, a, b) = \frac{(a^2 - b^2)^{p/2}} {\sqrt{2\pi}a^{p-0.5} K_p\Big(\sqrt{a^2 - b^2}\Big)} e^{bx} \times \frac{K_{p - 1/2} (a \sqrt{1 + x^2})} {(\sqrt{1 + x^2})^{1/2 - p}}\]for \(x, p \in ( - \infty; \infty)\), \(|b| < a\) if \(p \ge 0\), \(|b| \le a\) if \(p < 0\). \(K_{p}(.)\) denotes the modified Bessel function of the second kind and order \(p\) (scipy.special.kn)
genhyperbolic takes
pas a tail parameter,aas a shape parameter,bas a skewness parameter.
geninvgaussGeneralized Inverse Gaussian (help). The probability density function for geninvgauss is:\[f(x, p, b) = x^{p-1} \exp(-b (x + 1/x) / 2) / (2 K_p(b))\]where x > 0, and the parameters p, b satisfy b > 0. \(K_p\) is the modified Bessel function of second kind of order p (scipy.special.kv).
gilbratGilbrat (help). The probability density function for gilbrat is:\[f(x) = \frac{1}{x \sqrt{2\pi}} \exp(-\frac{1}{2} (\log(x))^2)\]gilbrat is a special case of lognorm with
s=1.
gompertzGompertz (Truncated Gumbel) (help). The probability density function for gompertz is:\[f(x, c) = c \exp(x) \exp(-c (e^x-1))\]for \(x \ge 0\), \(c > 0\).
gompertz takes
cas a shape parameter for \(c\).
gumbel_r(help). The probability density function for gumbel_r is:\[f(x) = \exp(-(x + e^{-x}))\]The Gumbel distribution is sometimes referred to as a type I Fisher-Tippett distribution. It is also related to the extreme value distribution, log-Weibull and Gompertz distributions.
gumbel_l(help). The probability density function for gumbel_l is:\[f(x) = \exp(x - e^x)\]The Gumbel distribution is sometimes referred to as a type I Fisher-Tippett distribution. It is also related to the extreme value distribution, log-Weibull and Gompertz distributions.
halfcauchyHalf Cauchy (help). The probability density function for halfcauchy is:\[f(x) = \frac{2}{\pi (1 + x^2)}\]for \(x \ge 0\).
halflogisticHalf Logistic (help). The probability density function for halflogistic is:\[f(x) = \frac{ 2 e^{-x} }{ (1+e^{-x})^2 } = \frac{1}{2} \text{sech}(x/2)^2\]for \(x \ge 0\).
halfnormHalf Normal (help). The probability density function for halfnorm is:\[f(x) = \sqrt{2/\pi} \exp(-x^2 / 2)\]for \(x >= 0\).
halfnorm is a special case of chi with
df=1.
halfgennormGeneralized Half Normal (help). The probability density function for halfgennorm is:\[f(x, \beta) = \frac{\beta}{\Gamma(1/\beta)} \exp(-|x|^\beta)\]for \(x > 0\). \(\Gamma\) is the gamma function (scipy.special.gamma).
gennorm takes
betaas a shape parameter for \(\beta\). For \(\beta = 1\), it is identical to an exponential distribution. For \(\beta = 2\), it is identical to a half normal distribution (withscale=1/sqrt(2)).
hypsecantHyperbolic Secant (help). The probability density function for hypsecant is:\[f(x) = \frac{1}{\pi} \text{sech}(x)\]for a real number \(x\).
invgammaInverse Gamma (help). The probability density function for invgamma is:\[f(x, a) = \frac{x^{-a-1}}{\Gamma(a)} \exp(-\frac{1}{x})\]for \(x >= 0\), \(a > 0\). \(\Gamma\) is the gamma function (scipy.special.gamma).
invgamma takes
aas a shape parameter for \(a\).invgamma is a special case of gengamma with
c=-1, and it is a different parameterization of the scaled inverse chi-squared distribution. Specifically, if the scaled inverse chi-squared distribution is parameterized with degrees of freedom \(\nu\) and scaling parameter \(\tau^2\), then it can be modeled using invgamma witha=\(\nu/2\) andscale=\(\nu \tau^2/2\).
invgaussInverse Gaussian (help). The probability density function for invgauss is:\[f(x, \mu) = \frac{1}{\sqrt{2 \pi x^3}} \exp(-\frac{(x-\mu)^2}{2 x \mu^2})\]for \(x >= 0\) and \(\mu > 0\).
invgauss takes
muas a shape parameter for \(\mu\).
invweibullInverse Weibull (help). The probability density function for invweibull is:\[f(x, c) = c x^{-c-1} \exp(-x^{-c})\]for \(x > 0\), \(c > 0\).
invweibull takes
cas a shape parameter for \(c\).
johnsonsbJohnson SB (help). The probability density function for johnsonsb is:\[f(x, a, b) = \frac{b}{x(1-x)} \phi(a + b \log \frac{x}{1-x} )\]where \(x\), \(a\), and \(b\) are real scalars; \(b > 0\) and \(x \in [0,1]\). \(\phi\) is the pdf of the normal distribution.
johnsonsb takes \(a\) and \(b\) as shape parameters.
johnsonsuJohnson SU (help). The probability density function for johnsonsu is:\[f(x, a, b) = \frac{b}{\sqrt{x^2 + 1}} \phi(a + b \log(x + \sqrt{x^2 + 1}))\]where \(x\), \(a\), and \(b\) are real scalars; \(b > 0\). \(\phi\) is the pdf of the normal distribution.
johnsonsu takes \(a\) and \(b\) as shape parameters.
kappa4Kappa 4 parameter (help). The probability density function for kappa4 is:\[f(x, h, k) = (1 - k x)^{1/k - 1} (1 - h (1 - k x)^{1/k})^{1/h-1}\]if \(h\) and \(k\) are not equal to 0.
If \(h\) or \(k\) are zero then the pdf can be simplified:
h = 0 and k != 0:
kappa4.pdf(x, h, k) = (1.0 - k*x)**(1.0/k - 1.0)* exp(-(1.0 - k*x)**(1.0/k))
h != 0 and k = 0:
kappa4.pdf(x, h, k) = exp(-x)*(1.0 - h*exp(-x))**(1.0/h - 1.0)
h = 0 and k = 0:
kappa4.pdf(x, h, k) = exp(-x)*exp(-exp(-x))
kappa4 takes \(h\) and \(k\) as shape parameters.
The kappa4 distribution returns other distributions when certain \(h\) and \(k\) values are used.
h
k=0.0
k=1.0
-inf<=k<=inf
-1.0
Logistic
logistic(x)
Generalized Logistic(1)
0.0
Gumbel
gumbel_r(x)
Reverse Exponential(2)
Generalized Extreme Value
genextreme(x, k)
1.0
Exponential
expon(x)
Uniform
uniform(x)
Generalized Pareto
genpareto(x, -k)
kappa3Kappa 3 parameter (help). The probability density function for kappa3 is:\[f(x, a) = a (a + x^a)^{-(a + 1)/a}\]for \(x > 0\) and \(a > 0\).
kappa3 takes
aas a shape parameter for \(a\).
ksoneDistribution of Kolmogorov-Smirnov one-sided test statistic (help). \(D_n^+\) and \(D_n^-\) are given by\[\begin{split}D_n^+ &= \text{sup}_x (F_n(x) - F(x)),\\ D_n^- &= \text{sup}_x (F(x) - F_n(x)),\\\end{split}\]where \(F\) is a continuous CDF and \(F_n\) is an empirical CDF. ksone describes the distribution under the null hypothesis of the KS test that the empirical CDF corresponds to \(n\) i.i.d. random variates with CDF \(F\).
kstwoDistribution of Kolmogorov-Smirnov two-sided test statistic (help). \(D_n\) is given by\[D_n = \text{sup}_x |F_n(x) - F(x)|\]where \(F\) is a (continuous) CDF and \(F_n\) is an empirical CDF. kstwo describes the distribution under the null hypothesis of the KS test that the empirical CDF corresponds to \(n\) i.i.d. random variates with CDF \(F\).
kstwobignLimiting Distribution of scaled Kolmogorov-Smirnov two-sided test statistic. (help). \(\sqrt{n} D_n\) is given by\[D_n = \text{sup}_x |F_n(x) - F(x)|\]where \(F\) is a continuous CDF and \(F_n\) is an empirical CDF. kstwobign describes the asymptotic distribution (i.e. the limit of \(\sqrt{n} D_n\)) under the null hypothesis of the KS test that the empirical CDF corresponds to i.i.d. random variates with CDF \(F\).
laplaceLaplace (help). The probability density function for laplace is\[f(x) = \frac{1}{2} \exp(-|x|)\]for a real number \(x\).
laplace_asymmetric(help). The probability density function for laplace_asymmetric is\[\begin{split}f(x, \kappa) &= \frac{1}{\kappa+\kappa^{-1}}\exp(-x\kappa),\quad x\ge0\\ &= \frac{1}{\kappa+\kappa^{-1}}\exp(x/\kappa),\quad x<0\\\end{split}\]for \(-\infty < x < \infty\), \(\kappa > 0\).
laplace_asymmetric takes
kappaas a shape parameter for \(\kappa\). For \(\kappa = 1\), it is identical to a Laplace distribution.
levyLevy (help). The probability density function for levy is:\[f(x) = \frac{1}{\sqrt{2\pi x^3}} \exp\left(-\frac{1}{2x}\right)\]for \(x >= 0\).
This is the same as the Levy-stable distribution with \(a=1/2\) and \(b=1\).
logisticLogistic (help). The probability density function for logistic is:\[f(x) = \frac{\exp(-x)} {(1+\exp(-x))^2}\]logistic is a special case of genlogistic with
c=1.Remark that the survival function (
logistic.sf) is equal to the Fermi-Dirac distribution describing fermionic statistics.
loggammaLog-Gamma (help). The probability density function for loggamma is:\[f(x, c) = \frac{\exp(c x - \exp(x))} {\Gamma(c)}\]for all \(x, c > 0\). Here, \(\Gamma\) is the gamma function (scipy.special.gamma).
loggamma takes
cas a shape parameter for \(c\).
loglaplaceLog-Laplace (Log Double Exponential) (help). The probability density function for loglaplace is:\[\begin{split}f(x, c) = \begin{cases}\frac{c}{2} x^{ c-1} &\text{for } 0 < x < 1\\ \frac{c}{2} x^{-c-1} &\text{for } x \ge 1 \end{cases}\end{split}\]for \(c > 0\).
loglaplace takes
cas a shape parameter for \(c\).
lognormLog-Normal (help). The probability density function for lognorm is:\[f(x, s) = \frac{1}{s x \sqrt{2\pi}} \exp\left(-\frac{\log^2(x)}{2s^2}\right)\]for \(x > 0\), \(s > 0\).
lognorm takes
sas a shape parameter for \(s\).
loguniformLog-Uniform (help). The probability density function for this class is:\[f(x, a, b) = \frac{1}{x \log(b/a)}\]for \(a \le x \le b\), \(b > a > 0\). This class takes \(a\) and \(b\) as shape parameters.
lomaxLomax (Pareto of the second kind) (help). The probability density function for lomax is:\[f(x, c) = \frac{c}{(1+x)^{c+1}}\]for \(x \ge 0\), \(c > 0\).
lomax takes
cas a shape parameter for \(c\).lomax is a special case of pareto with
loc=-1.0.
maxwellMaxwell (help). A special case of a chi distribution, withdf=3,loc=0.0, and givenscale = a, whereais the parameter used in the Mathworld description.The probability density function for maxwell is:
\[f(x) = \sqrt{2/\pi}x^2 \exp(-x^2/2)\]for \(x >= 0\).
mielkeMielke’s Beta-Kappa (help). The probability density function for mielke is:\[f(x, k, s) = \frac{k x^{k-1}}{(1+x^s)^{1+k/s}}\]for \(x > 0\) and \(k, s > 0\). The distribution is sometimes called Dagum distribution. It was already defined in, called a Burr Type III distribution (burr with parameters
c=sandd=k/s).mielke takes
kandsas shape parameters.
moyalMoyal (help). The probability density function for moyal is:\[f(x) = \exp(-(x + \exp(-x))/2) / \sqrt{2\pi}\]for a real number \(x\).
nakagamiNakagami (help). The probability density function for nakagami is:\[f(x, \nu) = \frac{2 \nu^\nu}{\Gamma(\nu)} x^{2\nu-1} \exp(-\nu x^2)\]for \(x >= 0\), \(\nu > 0\).
nakagami takes
nuas a shape parameter for \(\nu\).
ncx2Non-central chi-squared (help). The probability density function for ncx2 is:\[f(x, k, \lambda) = \frac{1}{2} \exp(-(\lambda+x)/2) (x/\lambda)^{(k-2)/4} I_{(k-2)/2}(\sqrt{\lambda x})\]for \(x >= 0\) and \(k, \lambda > 0\). \(k\) specifies the degrees of freedom (denoted
dfin the implementation) and \(\lambda\) is the non-centrality parameter (denotedncin the implementation). \(I_\nu\) denotes the modified Bessel function of first order of degree \(\nu\) (scipy.special.iv).ncx2 takes
dfandncas shape parameters.
ncfNon-central F (help). The probability density function for ncf is:\[\begin{split}f(x, n_1, n_2, \lambda) = \exp\left(\frac{\lambda}{2} + \lambda n_1 \frac{x}{2(n_1 x + n_2)} \right) n_1^{n_1/2} n_2^{n_2/2} x^{n_1/2 - 1} \\ (n_2 + n_1 x)^{-(n_1 + n_2)/2} \gamma(n_1/2) \gamma(1 + n_2/2) \\ \frac{L^{\frac{n_1}{2}-1}_{n_2/2} \left(-\lambda n_1 \frac{x}{2(n_1 x + n_2)}\right)} {B(n_1/2, n_2/2) \gamma\left(\frac{n_1 + n_2}{2}\right)}\end{split}\]for \(n_1, n_2 > 0\), \(\lambda \ge 0\). Here \(n_1\) is the degrees of freedom in the numerator, \(n_2\) the degrees of freedom in the denominator, \(\lambda\) the non-centrality parameter, \(\gamma\) is the logarithm of the Gamma function, \(L_n^k\) is a generalized Laguerre polynomial and \(B\) is the beta function.
ncf takes
df1,df2andncas shape parameters. Ifnc=0, the distribution becomes equivalent to the Fisher distribution.
nctNon-central Student’s T (help). If \(Y\) is a standard normal random variable and \(V\) is an independent chi-square random variable (chi2) with \(k\) degrees of freedom, then\[X = \frac{Y + c}{\sqrt{V/k}}\]has a non-central Student’s t distribution on the real line. The degrees of freedom parameter \(k\) (denoted
dfin the implementation) satisfies \(k > 0\) and the noncentrality parameter \(c\) (denotedncin the implementation) is a real number.
normNormal (Gaussian) (help). The probability density function for norm is:\[f(x) = \frac{\exp(-x^2/2)}{\sqrt{2\pi}}\]for a real number \(x\).
norminvgaussNormal Inverse Gaussian (help). The probability density function for norminvgauss is:\[f(x, a, b) = \frac{a \, K_1(a \sqrt{1 + x^2})}{\pi \sqrt{1 + x^2}} \, \exp(\sqrt{a^2 - b^2} + b x)\]where \(x\) is a real number, the parameter \(a\) is the tail heaviness and \(b\) is the asymmetry parameter satisfying \(a > 0\) and \(|b| <= a\). \(K_1\) is the modified Bessel function of second kind (scipy.special.k1).
paretoPareto (help). The probability density function for pareto is:\[f(x, b) = \frac{b}{x^{b+1}}\]for \(x \ge 1\), \(b > 0\).
pareto takes
bas a shape parameter for \(b\).
pearson3Pearson type III (help). The probability density function for pearson3 is:\[f(x, \kappa) = \frac{|\beta|}{\Gamma(\alpha)} (\beta (x - \zeta))^{\alpha - 1} \exp(-\beta (x - \zeta))\]where:
\[ \begin{align}\begin{aligned}\beta = \frac{2}{\kappa}\\\alpha = \beta^2 = \frac{4}{\kappa^2}\\\zeta = -\frac{\alpha}{\beta} = -\beta\end{aligned}\end{align} \]\(\Gamma\) is the gamma function (scipy.special.gamma). Pass the skew \(\kappa\) into pearson3 as the shape parameter
skew.
powerlawPower-function (help). The probability density function for powerlaw is:\[f(x, a) = a x^{a-1}\]for \(0 \le x \le 1\), \(a > 0\).
powerlaw takes
aas a shape parameter for \(a\).
powerlognormPower log normal (help). The probability density function for powerlognorm is:\[f(x, c, s) = \frac{c}{x s} \phi(\log(x)/s) (\Phi(-\log(x)/s))^{c-1}\]where \(\phi\) is the normal pdf, and \(\Phi\) is the normal cdf, and \(x > 0\), \(s, c > 0\).
powerlognorm takes \(c\) and \(s\) as shape parameters.
powernormPower normal (help). The probability density function for powernorm is:\[f(x, c) = c \phi(x) (\Phi(-x))^{c-1}\]where \(\phi\) is the normal pdf, and \(\Phi\) is the normal cdf, and \(x >= 0\), \(c > 0\).
powernorm takes
cas a shape parameter for \(c\).
rdistR-distribution (help). The probability density function for rdist is:\[f(x, c) = \frac{(1-x^2)^{c/2-1}}{B(1/2, c/2)}\]for \(-1 \le x \le 1\), \(c > 0\). rdist is also called the symmetric beta distribution: if B has a beta distribution with parameters (c/2, c/2), then X = 2*B - 1 follows a R-distribution with parameter c.
rdist takes
cas a shape parameter for \(c\).This distribution includes the following distribution kernels as special cases:
c = 2: uniform c = 3: `semicircular` c = 4: Epanechnikov (parabolic) c = 6: quartic (biweight) c = 8: triweight
rayleighRayleigh (help). The probability density function for rayleigh is:\[f(x) = x \exp(-x^2/2)\]for \(x \ge 0\).
rayleigh is a special case of chi with
df=2.
riceRice (help). The probability density function for rice is:\[f(x, b) = x \exp(- \frac{x^2 + b^2}{2}) I_0(x b)\]for \(x >= 0\), \(b > 0\). \(I_0\) is the modified Bessel function of order zero (scipy.special.i0).
rice takes
bas a shape parameter for \(b\).
recipinvgaussReciprocal Inverse Gaussian (help). The probability density function for recipinvgauss is:\[f(x, \mu) = \frac{1}{\sqrt{2\pi x}} \exp\left(\frac{-(1-\mu x)^2}{2\mu^2x}\right)\]for \(x \ge 0\).
recipinvgauss takes
muas a shape parameter for \(\mu\).
semicircularSemicircular (help). The probability density function for semicircular is:\[f(x) = \frac{2}{\pi} \sqrt{1-x^2}\]for \(-1 \le x \le 1\).
The distribution is a special case of rdist with c = 3.
skewcauchySkew Cauchy (help). The probability density function for skewcauchy is:\[f(x) = \frac{1}{\pi \left(\frac{x^2}{\left(a\, \text{sign}(x) + 1 \right)^2} + 1 \right)}\]for a real number \(x\) and skewness parameter \(-1 < a < 1\).
When \(a=0\), the distribution reduces to the usual Cauchy distribution.
skewnormSkew normal (help). The pdf is:skewnorm.pdf(x, a) = 2 * norm.pdf(x) * norm.cdf(a*x)
skewnorm takes a real number \(a\) as a skewness parameter. When
a = 0the distribution is identical to a normal distribution (norm).
studentized_range(help). The probability density function for studentized_range is:\[f(x; k, \nu) = \frac{k(k-1)\nu^{\nu/2}}{\Gamma(\nu/2) 2^{\nu/2-1}} \int_{0}^{\infty} \int_{-\infty}^{\infty} s^{\nu} e^{-\nu s^2/2} \phi(z) \phi(sx + z) [\Phi(sx + z) - \Phi(z)]^{k-2} \,dz \,ds\]for \(x ≥ 0\), \(k > 1\), and \(\nu > 0\).
studentized_range takes
kfor \(k\) anddffor \(\nu\) as shape parameters.When \(\nu\) exceeds 100,000, an asymptotic approximation (infinite degrees of freedom) is used to compute the cumulative distribution function.
tStudent’s T (help). The probability density function for t is:\[f(x, \nu) = \frac{\Gamma((\nu+1)/2)} {\sqrt{\pi \nu} \Gamma(\nu/2)} (1+x^2/\nu)^{-(\nu+1)/2}\]where \(x\) is a real number and the degrees of freedom parameter \(\nu\) (denoted
dfin the implementation) satisfies \(\nu > 0\). \(\Gamma\) is the gamma function (scipy.special.gamma).
trapezoidTrapezoidal (help). The trapezoidal distribution can be represented with an up-sloping line fromlocto(loc + c*scale), then constant to(loc + d*scale)and then downsloping from(loc + d*scale)to(loc+scale). This defines the trapezoid base fromlocto(loc+scale)and the flat top fromctodproportional to the position along the base with0 <= c <= d <= 1. Whenc=d, this is equivalent to triang with the same values for loc, scale and c.trapezoid takes \(c\) and \(d\) as shape parameters.
triangTriangular (help). The triangular distribution can be represented with an up-sloping line fromlocto(loc + c*scale)and then downsloping for(loc + c*scale)to(loc + scale).triang takes
cas a shape parameter for \(c\).
truncexponTruncated Exponential (help). The probability density function for truncexpon is:\[f(x, b) = \frac{\exp(-x)}{1 - \exp(-b)}\]for \(0 <= x <= b\).
truncexpon takes
bas a shape parameter for \(b\).
truncnormTruncated Normal (help). The standard form of this distribution is a standard normal truncated to the range [a, b] — notice that a and b are defined over the domain of the standard normal. To convert clip values for a specific mean and standard deviation, use:a, b = (myclip_a - my_mean) / my_std, (myclip_b - my_mean) / my_std
truncnorm takes \(a\) and \(b\) as shape parameters.
tukeylambdaTukey-Lambda (help). A flexible distribution, able to represent and interpolate between the following distributions:Cauchy (\(lambda = -1\))
logistic (\(lambda = 0\))
approx Normal (\(lambda = 0.14\))
uniform from -1 to 1 (\(lambda = 1\))
tukeylambda takes a real number \(lambda\) (denoted
lamin the implementation) as a shape parameter.
uniformUniform (help). a uniform continuous random variable
vonmisesVon-Mises (Circular) (help). The probability density function for vonmises and vonmises_line is:\[f(x, \kappa) = \frac{ \exp(\kappa \cos(x)) }{ 2 \pi I_0(\kappa) }\]for \(-\pi \le x \le \pi\), \(\kappa > 0\). \(I_0\) is the modified Bessel function of order zero (scipy.special.i0).
vonmises is a circular distribution which does not restrict the distribution to a fixed interval. Currently, there is no circular distribution framework in scipy. The
cdfis implemented such thatcdf(x + 2*np.pi) == cdf(x) + 1.vonmises_line is the same distribution, defined on \([-\pi, \pi]\) on the real line. This is a regular (i.e. non-circular) distribution.
vonmises and vonmises_line take
kappaas a shape parameter.
vonmises_line(help). The probability density function for vonmises and vonmises_line is:\[f(x, \kappa) = \frac{ \exp(\kappa \cos(x)) }{ 2 \pi I_0(\kappa) }\]for \(-\pi \le x \le \pi\), \(\kappa > 0\). \(I_0\) is the modified Bessel function of order zero (scipy.special.i0).
vonmises is a circular distribution which does not restrict the distribution to a fixed interval. Currently, there is no circular distribution framework in scipy. The
cdfis implemented such thatcdf(x + 2*np.pi) == cdf(x) + 1.vonmises_line is the same distribution, defined on \([-\pi, \pi]\) on the real line. This is a regular (i.e. non-circular) distribution.
vonmises and vonmises_line take
kappaas a shape parameter.
waldWald (help). The probability density function for wald is:\[f(x) = \frac{1}{\sqrt{2\pi x^3}} \exp(- \frac{ (x-1)^2 }{ 2x })\]for \(x >= 0\).
wald is a special case of invgauss with
mu=1.
weibull_min(help). The probability density function for weibull_min is:\[f(x, c) = c x^{c-1} \exp(-x^c)\]for \(x > 0\), \(c > 0\).
weibull_min takes
cas a shape parameter for \(c\). (named \(k\) in Wikipedia article and \(a\) innumpy.random.weibull). Special shape values are \(c=1\) and \(c=2\) where Weibull distribution reduces to the expon and rayleigh distributions respectively.
weibull_max(help). The probability density function for weibull_max is:\[f(x, c) = c (-x)^{c-1} \exp(-(-x)^c)\]for \(x < 0\), \(c > 0\).
weibull_max takes
cas a shape parameter for \(c\).
wrapcauchyWrapped Cauchy (help). The probability density function for wrapcauchy is:\[f(x, c) = \frac{1-c^2}{2\pi (1+c^2 - 2c \cos(x))}\]for \(0 \le x \le 2\pi\), \(0 < c < 1\).
wrapcauchy takes
cas a shape parameter for \(c\).