{ } Raw JSON

bundles / scipy latest / scipy / stats / _continuous_distns / truncpareto_gen

class

scipy.stats._continuous_distns:truncpareto_gen

source: /scipy/stats/_continuous_distns.py :10459

Signature

class   truncpareto_gen ( momtype = 1 a = None b = None xtol = 1e-14 badvalue = None name = None longname = None shapes = None seed = None )

Members

Summary

An upper truncated Pareto continuous random variable.

Extended Summary

%(before_notes)s

Notes

The probability density function for truncpareto is:

for , and .

truncpareto takes b and c as shape parameters for and .

Notice that the upper truncation value is defined in standardized form so that random values of an unscaled, unshifted variable are within the range [1, c]. If u_r is the upper bound to a scaled and/or shifted variable, then c = (u_r - loc) / scale. In other words, the support of the distribution becomes (scale + loc) <= x <= (c*scale + loc) when scale and/or loc are provided.

The fit method assumes that is positive; it does not produce good results when the data is more consistent with negative .

truncpareto can also be used to model a general power law distribution with PDF:

for and . Suppose , , and are represented in code as a, l, and h, respectively. In this case, use truncpareto with parameters b = -a, c = h / l, scale = l, and loc = 0.

%(after_notes)s

See also

pareto

Pareto distribution

Aliases

  • scipy.stats._continuous_distns.truncpareto_gen