statsmodels.genmod.families.family.Family.deviance¶
-
Family.
deviance
(endog, mu, scale=1.0)[source]¶ Deviance of (endog,mu) pair.
Deviance is usually defined as twice the loglikelihood ratio.
Parameters: endog : array-like
The endogenous response variable
mu : array-like
The inverse of the link function at the linear predicted values.
scale : float, optional
An optional scale argument
Returns: Deviance : array
The value of deviance function defined below.
Notes
Deviance is defined
where y is the endogenous variable. The deviance functions are analytically defined for each family.