miscmodels.count.PoissonOffsetGMLE()

statsmodels.miscmodels.count.PoissonOffsetGMLE class statsmodels.miscmodels.count.PoissonOffsetGMLE(endog, exog=None, offset=None, missing='none', **kwds) [source] Maximum Likelihood Estimation of Poisson Model This is an example for generic MLE which has the same statistical model as discretemod.Poisson but adds offset Except for defining the negative log-likelihood method, all methods and results are generic. Gradients and Hessian and all resulting statistics are based on numerical differe

miscmodels.count.PoissonGMLE()

statsmodels.miscmodels.count.PoissonGMLE class statsmodels.miscmodels.count.PoissonGMLE(endog, exog=None, loglike=None, score=None, hessian=None, missing='none', extra_params_names=None, **kwds) [source] Maximum Likelihood Estimation of Poisson Model This is an example for generic MLE which has the same statistical model as discretemod.Poisson. Except for defining the negative log-likelihood method, all methods and results are generic. Gradients and Hessian and all resulting statistics are b

Maximum Likelihood Estimation (Generic models)

Maximum Likelihood Estimation (Generic models) Link to Notebook GitHub This tutorial explains how to quickly implement new maximum likelihood models in statsmodels. We give two examples: Probit model for binary dependent variables Negative binomial model for count data The GenericLikelihoodModel class eases the process by providing tools such as automatic numeric differentiation and a unified interface to scipy optimization functions. Using statsmodels, users can fit new MLE models simply

M-Estimators for Robust Linear Modeling

M-Estimators for Robust Linear Modeling Link to Notebook GitHub In [1]: from __future__ import print_function from statsmodels.compat import lmap import numpy as np from scipy import stats import matplotlib.pyplot as plt import statsmodels.api as sm An M-estimator minimizes the function $$Q(e_i, \rho) = \sum_i~\rho \left (\frac{e_i}{s}\right )$$ where $\rho$ is a symmetric function of the residuals The effect of $\rho$ is to reduce the influence of outliers $s$ is an estimate

LogTransf_gen.var()

statsmodels.sandbox.distributions.transformed.LogTransf_gen.var LogTransf_gen.var(*args, **kwds) Variance of the distribution Parameters: arg1, arg2, arg3,... : array_like The shape parameter(s) for the distribution (see docstring of the instance object for more information) loc : array_like, optional location parameter (default=0) scale : array_like, optional scale parameter (default=1) Returns: var : float the variance of the distribution

LogTransf_gen.std()

statsmodels.sandbox.distributions.transformed.LogTransf_gen.std LogTransf_gen.std(*args, **kwds) Standard deviation of the distribution. Parameters: arg1, arg2, arg3,... : array_like The shape parameter(s) for the distribution (see docstring of the instance object for more information) loc : array_like, optional location parameter (default=0) scale : array_like, optional scale parameter (default=1) Returns: std : float standard deviation of the distribution

LogTransf_gen.stats()

statsmodels.sandbox.distributions.transformed.LogTransf_gen.stats LogTransf_gen.stats(*args, **kwds) Some statistics of the given RV Parameters: arg1, arg2, arg3,... : array_like The shape parameter(s) for the distribution (see docstring of the instance object for more information) loc : array_like, optional location parameter (default=0) scale : array_like, optional (discrete RVs only) scale parameter (default=1) moments : str, optional composed of letters [?mvsk?] defining which mo

LogTransf_gen.sf()

statsmodels.sandbox.distributions.transformed.LogTransf_gen.sf LogTransf_gen.sf(x, *args, **kwds) Survival function (1-cdf) at x of the given RV. Parameters: x : array_like quantiles arg1, arg2, arg3,... : array_like The shape parameter(s) for the distribution (see docstring of the instance object for more information) loc : array_like, optional location parameter (default=0) scale : array_like, optional scale parameter (default=1) Returns: sf : array_like Survival function evalu

LogTransf_gen.rvs()

statsmodels.sandbox.distributions.transformed.LogTransf_gen.rvs LogTransf_gen.rvs(*args, **kwds) Random variates of given type. Parameters: arg1, arg2, arg3,... : array_like The shape parameter(s) for the distribution (see docstring of the instance object for more information). loc : array_like, optional Location parameter (default=0). scale : array_like, optional Scale parameter (default=1). size : int or tuple of ints, optional Defining number of random variates (default=1). Retu

LogTransf_gen.ppf()

statsmodels.sandbox.distributions.transformed.LogTransf_gen.ppf LogTransf_gen.ppf(q, *args, **kwds) Percent point function (inverse of cdf) at q of the given RV. Parameters: q : array_like lower tail probability arg1, arg2, arg3,... : array_like The shape parameter(s) for the distribution (see docstring of the instance object for more information) loc : array_like, optional location parameter (default=0) scale : array_like, optional scale parameter (default=1) Returns: x : array_l