BinaryResults.save()

statsmodels.discrete.discrete_model.BinaryResults.save BinaryResults.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. Notes If remo

stats.sandwich_covariance.cov_cluster_2groups()

statsmodels.stats.sandwich_covariance.cov_cluster_2groups statsmodels.stats.sandwich_covariance.cov_cluster_2groups(results, group, group2=None, use_correction=True) [source] cluster robust covariance matrix for two groups/clusters Parameters: results : result instance result of a regression, uses results.model.exog and results.resid TODO: this should use wexog instead use_correction : bool If true (default), then the small sample correction factor is used. Returns: cov_both : ndarray

Poisson.jac()

statsmodels.discrete.discrete_model.Poisson.jac Poisson.jac(*args, **kwds) jac is deprecated, use score_obs instead! Use score_obs method. jac will be removed in 0.7 Poisson model Jacobian of the log-likelihood for each observation Parameters: params : array-like The parameters of the model Returns: score : ndarray (nobs, k_vars) The score vector of the model evaluated at params Notes for observations where the loglinear model is assumed

MultinomialResults.cov_params()

statsmodels.discrete.discrete_model.MultinomialResults.cov_params MultinomialResults.cov_params(r_matrix=None, column=None, scale=None, cov_p=None, other=None) Returns the variance/covariance matrix. The variance/covariance matrix can be of a linear contrast of the estimates of params or all params multiplied by scale which will usually be an estimate of sigma^2. Scale is assumed to be a scalar. Parameters: r_matrix : array-like Can be 1d, or 2d. Can be used alone or with other. column :

RamsayE.weights()

statsmodels.robust.norms.RamsayE.weights RamsayE.weights(z) [source] Ramsay?s Ea weighting function for the IRLS algorithm The psi function scaled by z Parameters: z : array-like 1d array Returns: weights : array weights(z) = exp(-a*|z|)

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

Binomial.resid_anscombe()

statsmodels.genmod.families.family.Binomial.resid_anscombe Binomial.resid_anscombe(endog, mu) [source] The Anscombe residuals Parameters: endog : array-like Endogenous response variable mu : array-like Fitted mean response variable Returns: resid_anscombe : array The Anscombe residuals as defined below. Notes sqrt(n)*(cox_snell(endog)-cox_snell(mu))/(mu**(1/6.)*(1-mu)**(1/6.)) where cox_snell is defined as cox_snell(x) = betainc(2/3., 2/3., x)*betainc(2/3.,2/3.) where betainc is th

GEEResults.save()

statsmodels.genmod.generalized_estimating_equations.GEEResults.save GEEResults.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. Not

static KDEUnivariate.cumhazard()

statsmodels.nonparametric.kde.KDEUnivariate.cumhazard static KDEUnivariate.cumhazard() [source] Returns the hazard function evaluated at the support. Notes Will not work if fit has not been called.

sandbox.stats.runs.symmetry_bowker()

statsmodels.sandbox.stats.runs.symmetry_bowker statsmodels.sandbox.stats.runs.symmetry_bowker(table) [source] Test for symmetry of a (k, k) square contingency table This is an extension of the McNemar test to test the Null hypothesis that the contingency table is symmetric around the main diagonal, that is n_{i, j} = n_{j, i} for all i, j Parameters: table : array_like, 2d, (k, k) a square contingency table that contains the count for k categories in rows and columns. Returns: statistic