def get_distribution(self, params, exog=None, exog_infl=None, exposure=None, offset=None):
    'Get frozen instance of distribution based on predicted parameters.\n\n        Parameters\n        ----------\n        params : array_like\n            The parameters of the model.\n        exog : ndarray, optional\n            Explanatory variables for the main count model.\n            If ``exog`` is None, then the data from the model will be used.\n        exog_infl : ndarray, optional\n            Explanatory variables for the zero-inflation model.\n            ``exog_infl`` has to be provided if ``exog`` was provided unless\n            ``exog_infl`` in the model is only a constant.\n        offset : ndarray, optional\n            Offset is added to the linear predictor of the mean function with\n            coefficient equal to 1.\n            Default is zero if exog is not None, and the model offset if exog\n            is None.\n        exposure : ndarray, optional\n            Log(exposure) is added to the linear predictor  of the mean\n            function with coefficient equal to 1. If exposure is specified,\n            then it will be logged by the method. The user does not need to\n            log it first.\n            Default is one if exog is is not None, and it is the model exposure\n            if exog is None.\n\n        Returns\n        -------\n        Instance of frozen scipy distribution subclass.\n        '
    mu = self.predict(params, exog=exog, exog_infl=exog_infl, exposure=exposure, offset=offset, which='mean-main')
    w = self.predict(params, exog=exog, exog_infl=exog_infl, exposure=exposure, offset=offset, which='prob-main')
    distr = self.distribution(mu[:, None], (1 - w[:, None]))
    return distr
Get frozen instance of distribution based on predicted parameters.

Parameters
----------
params : array_like
    The parameters of the model.
exog : ndarray, optional
    Explanatory variables for the main count model.
    If ``exog`` is None, then the data from the model will be used.
exog_infl : ndarray, 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.
offset : ndarray, 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.
exposure : ndarray, 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.
def get_distribution(self, params, exog=None, exog_infl=None, exposure=None, offset=None):
    'Get frozen instance of distribution based on predicted parameters.\n\n        Parameters\n        ----------\n        params : array_like\n            The parameters of the model.\n        exog : ndarray, optional\n            Explanatory variables for the main count model.\n            If ``exog`` is None, then the data from the model will be used.\n        exog_infl : ndarray, optional\n            Explanatory variables for the zero-inflation model.\n            ``exog_infl`` has to be provided if ``exog`` was provided unless\n            ``exog_infl`` in the model is only a constant.\n        offset : ndarray, optional\n            Offset is added to the linear predictor of the mean function with\n            coefficient equal to 1.\n            Default is zero if exog is not None, and the model offset if exog\n            is None.\n        exposure : ndarray, optional\n            Log(exposure) is added to the linear predictor  of the mean\n            function with coefficient equal to 1. If exposure is specified,\n            then it will be logged by the method. The user does not need to\n            log it first.\n            Default is one if exog is is not None, and it is the model exposure\n            if exog is None.\n\n        Returns\n        -------\n        Instance of frozen scipy distribution subclass.\n        '
    mu = self.predict(params, exog=exog, exog_infl=exog_infl, exposure=exposure, offset=offset, which='mean-main')
    w = self.predict(params, exog=exog, exog_infl=exog_infl, exposure=exposure, offset=offset, which='prob-main')
    distr = self.distribution(mu[:, None], (1 - w[:, None]))
    return distr