http://blog.csdn.net/pipisorry/article/details/49515215
统计函数Statistical functions(scipy.stats)
Python有一个很好的统计推断包。那就是scipy里面的stats。
This module contains a large number of probability distributions as well as a growing library of statistical functions.
Each included distribution is an instance of the class rv_continous: For each given name the following methods are
available:
连续的
rv_continuous([momtype, a, b, xtol, ...]) A generic continuous random variable class meant for subclassing.
rv_continuous.pdf(x, *args, **kwds) Probability density function at x of the given RV.
rv_continuous.logpdf(x, *args, **kwds) Log of the probability density function at x of the given RV.
rv_continuous.cdf(x, *args, **kwds) Cumulative distribution function of the given RV.
rv_continuous.logcdf(x, *args, **kwds) Log of the cumulative distribution function at x of the given RV.
rv_continuous.sf(x, *args, **kwds) Survival function (1-cdf) at x of the given RV.
rv_continuous.logsf(x, *args, **kwds) Log of the survival function of the given RV.
rv_continuous.ppf(q, *args, **kwds) Percent point function (inverse of cdf) at q of the given RV.
rv_continuous.isf(q, *args, **kwds) Inverse survival function at q of the given RV.
rv_continuous.moment(n, *args, **kwds) n’th order non-central moment of distribution.
rv_continuous.stats(*args, **kwds) Some statistics of the given RV
rv_continuous.entropy(*args, **kwds) Differential entropy of the RV.
rv_continuous.fit(data, *args, **kwds) Return MLEs for shape, location, and scale parameters from data.
rv_continuous.expect([func, args, loc, ...]) Calculate expected value of a function with respect to the distribution.
离散的
rv_discrete([a, b, name, badvalue, ...]) A generic discrete random variable class meant for subclassing.
rv_discrete.rvs(*args, **kwargs) Random variates of given type.
rv_discrete.pmf(k, *args, **kwds) Probability mass function at k of the given RV.
rv_discrete.logpmf(k, *args, **kwds) Log of the probability mass function at k of the given RV.
rv_discrete.cdf(k, *args, **kwds) Cumulative distribution function of the given RV.
rv_discrete.logcdf(k, *args, **kwds) Log of the cumulative distribution function at k of the given RV
rv_discrete.sf(k, *args, **kwds) Survival function (1-cdf) at k of the given RV.
rv_discrete.logsf(k, *args, **kwds) Log of the survival function of the given RV.
rv_discrete.ppf(q, *args, **kwds) Percent point function (inverse of cdf) at q of the given RV
rv_discrete.isf(q, *args, **kwds) Inverse survival function (1-sf) at q of the given RV.
rv_discrete.stats(*args, **kwds) Some statistics of the given RV
rv_discrete.moment(n, *args, **kwds) n’th order non-central moment of distribution.
rv_discrete.entropy(*args, **kwds) Differential entropy of the RV.
rv_discrete.expect([func, args, loc, lb, ...]) Calculate expected value of a function with respect to the distribution
连续分布
alpha An alpha continuous random variable.
anglit An anglit continuous random variable.
arcsine An arcsine continuous random variable.
beta A beta continuous random variable.
betaprime A beta prime continuous random variable.
bradford A Bradford continuous random variable.
burr A Burr continuous random variable.
cauchy A Cauchy continuous random variable.
chi A chi continuous random variable.
chi2 A chi-squared continuous random variable.
cosine A cosine continuous random variable.
dgamma A double gamma continuous random variable.
dweibull A double Weibull continuous random variable.
erlang An Erlang continuous random variable.
expon An exponential continuous random variable.
exponweib An exponentiated Weibull continuous random variable.
exponpow An exponential power continuous random variable.
f An F continuous random variable.
fatiguelife A fatigue-life (Birnbaum-Sanders) continuous random variable.
fisk A Fisk continuous random variable.
foldcauchy A folded Cauchy cont