QuantRegResults.save()

statsmodels.regression.quantile_regression.QuantRegResults.save QuantRegResults.save(fname, remove_data=False) save a pickle of this instance Parameters: fname : string or filehandle fname can be a string to a file path or filename, or a filehandle. remove_data : bool If False (default), then the instance is pickled without changes. If True, then all arrays with length nobs are set to None before pickling. See the remove_data method. In some cases not all arrays will be set to None. No

NegativeBinomial.from_formula()

statsmodels.discrete.discrete_model.NegativeBinomial.from_formula classmethod NegativeBinomial.from_formula(formula, data, subset=None, *args, **kwargs) Create a Model from a formula and dataframe. Parameters: formula : str or generic Formula object The formula specifying the model data : array-like The data for the model. See Notes. subset : array-like An array-like object of booleans, integers, or index values that indicate the subset of df to use in the model. Assumes df is a pandas

CovStruct.update()

statsmodels.genmod.cov_struct.CovStruct.update CovStruct.update(params) [source] Updates the association parameter values based on the current regression coefficients. Parameters: params : array-like Working values for the regression parameters.

ArmaFft.acf()

statsmodels.sandbox.tsa.fftarma.ArmaFft.acf ArmaFft.acf(nobs=None) theoretical autocorrelation function of an ARMA process Parameters: ar : array_like, 1d coefficient for autoregressive lag polynomial, including zero lag ma : array_like, 1d coefficient for moving-average lag polynomial, including zero lag nobs : int number of terms (lags plus zero lag) to include in returned acf Returns: acf : array autocorrelation of ARMA process given by ar, ma See also arma_acovf, acf, acovf

CLogLog.inverse_deriv()

statsmodels.genmod.families.links.CLogLog.inverse_deriv CLogLog.inverse_deriv(z) [source] Derivative of the inverse of the C-Log-Log transform link function Parameters: z : array-like The value of the inverse of the CLogLog link function at p Returns: The derivative of the inverse of the CLogLog link function :

PoissonOffsetGMLE.nloglikeobs()

statsmodels.miscmodels.count.PoissonOffsetGMLE.nloglikeobs PoissonOffsetGMLE.nloglikeobs(params) [source] Loglikelihood of Poisson model Parameters: params : array-like The parameters of the model. Returns: The log likelihood of the model evaluated at `params` : Notes

GLSAR.hessian()

statsmodels.regression.linear_model.GLSAR.hessian GLSAR.hessian(params) The Hessian matrix of the model

Quantile regression

Quantile regression Link to Notebook GitHub This example page shows how to use statsmodels' QuantReg class to replicate parts of the analysis published in Koenker, Roger and Kevin F. Hallock. "Quantile Regressioin". Journal of Economic Perspectives, Volume 15, Number 4, Fall 2001, Pages 143?156 We are interested in the relationship between income and expenditures on food for a sample of working class Belgian households in 1857 (the Engel data). Setup We first need to load some modules and

Logit.hessian()

statsmodels.discrete.discrete_model.Logit.hessian Logit.hessian(params) [source] Logit model Hessian matrix of the log-likelihood Parameters: params : array-like The parameters of the model Returns: hess : ndarray, (k_vars, k_vars) The Hessian, second derivative of loglikelihood function, evaluated at params Notes

GLMResults.remove_data()

statsmodels.genmod.generalized_linear_model.GLMResults.remove_data GLMResults.remove_data() [source] remove data arrays, all nobs arrays from result and model This reduces the size of the instance, so it can be pickled with less memory. Currently tested for use with predict from an unpickled results and model instance. Warning Since data and some intermediate results have been removed calculating new statistics that require them will raise exceptions. The exception will occur the first time