Nested.update()

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

Nested.summary()

statsmodels.genmod.cov_struct.Nested.summary Nested.summary() [source] Returns a summary string describing the state of the dependence structure.

Nested.initialize()

statsmodels.genmod.cov_struct.Nested.initialize Nested.initialize(model) [source] Called on the first call to update ilabels is a list of n_i x n_i matrices containing integer labels that correspond to specific correlation parameters. Two elements of ilabels[i] with the same label share identical variance components. designx is a matrix, with each row containing dummy variables indicating which variance components are associated with the corresponding element of QY.

Nested.covariance_matrix_solve()

statsmodels.genmod.cov_struct.Nested.covariance_matrix_solve Nested.covariance_matrix_solve(expval, index, stdev, rhs) Solves matrix equations of the form covmat * soln = rhs and returns the values of soln, where covmat is the covariance matrix represented by this class. Parameters: expval: array-like : The expected value of endog for each observed value in the group. index: integer : The group index. stdev : array-like The standard deviation of endog for each observation in the group.

Nested.covariance_matrix()

statsmodels.genmod.cov_struct.Nested.covariance_matrix Nested.covariance_matrix(expval, index) [source] Returns the working covariance or correlation matrix for a given cluster of data. Parameters: endog_expval: array-like : The expected values of endog for the cluster for which the covariance or correlation matrix will be returned index: integer : The index of the cluster for which the covariane or correlation matrix will be returned Returns: M: matrix : The covariance or correlatio

NegativeBinomialResults.wald_test()

statsmodels.discrete.discrete_model.NegativeBinomialResults.wald_test NegativeBinomialResults.wald_test(r_matrix, cov_p=None, scale=1.0, invcov=None, use_f=None) Compute a Wald-test for a joint linear hypothesis. Parameters: r_matrix : array-like, str, or tuple array : An r x k array where r is the number of restrictions to test and k is the number of regressors. It is assumed that the linear combination is equal to zero. str : The full hypotheses to test can be given as a string. See the

NegativeBinomialResults.t_test()

statsmodels.discrete.discrete_model.NegativeBinomialResults.t_test NegativeBinomialResults.t_test(r_matrix, cov_p=None, scale=None, use_t=None) Compute a t-test for a each linear hypothesis of the form Rb = q Parameters: r_matrix : array-like, str, tuple array : If an array is given, a p x k 2d array or length k 1d array specifying the linear restrictions. It is assumed that the linear combination is equal to zero. str : The full hypotheses to test can be given as a string. See the example

NegativeBinomialResults.summary2()

statsmodels.discrete.discrete_model.NegativeBinomialResults.summary2 NegativeBinomialResults.summary2(yname=None, xname=None, title=None, alpha=0.05, float_format='%.4f') Experimental function to summarize regression results Parameters: xname : List of strings of length equal to the number of parameters Names of the independent variables (optional) yname : string Name of the dependent variable (optional) title : string, optional Title for the top table. If not None, then this replaces

NegativeBinomialResults.summary()

statsmodels.discrete.discrete_model.NegativeBinomialResults.summary NegativeBinomialResults.summary(yname=None, xname=None, title=None, alpha=0.05, yname_list=None) Summarize the Regression Results Parameters: yname : string, optional Default is y xname : list of strings, optional Default is var_## for ## in p the number of regressors title : string, optional Title for the top table. If not None, then this replaces the default title alpha : float significance level for the confidence

NegativeBinomialResults.save()

statsmodels.discrete.discrete_model.NegativeBinomialResults.save NegativeBinomialResults.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 N