statsmodels.discrete.discrete_model.Logit.predict¶
-
Logit.predict(params, exog=
None, which='mean', linear=None, offset=None)¶ Predict response variable of a model given exogenous variables.
- Parameters:¶
- params : array_like¶
Fitted parameters of the model.
- exog : array_like¶
1d or 2d array of exogenous values. If not supplied, the whole exog attribute of the model is used.
- which : {'mean', 'linear', 'var', 'prob'}, optional¶
Statistic to predict. Default is ‘mean’.
’mean’ returns the conditional expectation of endog E(y | x), i.e. exp of linear predictor.
’linear’ returns the linear predictor of the mean function.
’var’ returns the estimated variance of endog implied by the model.
- linear : bool¶
If True, returns the linear predicted values. If False or None, then the statistic specified by
whichwill be returned.
- Returns:¶
Fitted values at exog.
- Return type:¶
array