4.1.9.1.4. statsmodels.base._penalties.Penalty

class statsmodels.base._penalties.Penalty(wts)[source]

A class for representing a scalar-value penalty.

Parameters:

wts : array-like

A vector of weights that determines the weight of the penalty for each parameter.

Notes

The class has a member called alpha that scales the weights.

__init__(wts)[source]

4.1.9.1.4.1. Methods

__init__(wts)
func(params) A penalty function on a vector of parameters.
grad(params) The gradient of a penalty function.