statsmodels.discrete.count_model.ZeroInflatedNegativeBinomialP.get_distribution

ZeroInflatedNegativeBinomialP.get_distribution(params, exog=None, exog_infl=None, exposure=None, offset=None)[source]

Get frozen instance of distribution based on predicted parameters.

Parameters:
paramsarray_like

The parameters of the model.

exogndarray, optional

Explanatory variables for the main count model. If exog is None, then the data from the model will be used.

exog_inflndarray, optional

Explanatory variables for the zero-inflation model. exog_infl has to be provided if exog was provided unless exog_infl in the model is only a constant.

offsetndarray, optional

Offset is added to the linear predictor of the mean function with coefficient equal to 1. Default is zero if exog is not None, and the model offset if exog is None.

exposurendarray, optional

Log(exposure) is added to the linear predictor of the mean function with coefficient equal to 1. If exposure is specified, then it will be logged by the method. The user does not need to log it first. Default is one if exog is is not None, and it is the model exposure if exog is None.

Returns:
Instance of frozen scipy distribution subclass.

Last update: Dec 11, 2024