adelie.glm.gaussian#
- adelie.glm.gaussian(y: ndarray, *, weights: ndarray | None = None, dtype: float32 | float64 | None = None, opt: bool = True)[source]#
- Creates a Gaussian GLM family object. - The Gaussian GLM family specifies the loss function as: \[\begin{align*} \ell(\eta) = \sum\limits_{i=1}^n w_i \left( -y_i \eta_i + \frac{\eta_i^2}{2} \right) \end{align*}\]- The link function is given by \[\begin{align*} g(\mu)_i &= \mu_i \end{align*}\]- Parameters:
- y(n,) ndarray
- Response vector \(y\). 
- weights(n,) ndarray, optional
- Observation weights \(W\). Weights are normalized such that they sum to - 1. Default is- None, in which case, it is set to- np.full(n, 1/n).
- dtypeUnion[float32, float64], optional
- The underlying data type. If - None, it is inferred from- y, in which case- ymust have an underlying data type of- numpy.float32or- numpy.float64. Default is- None.
- optbool, optional
- If - True, an optimized routine is used when passed into- adelie.solver.grpnet(). Otherwise, a general routine with IRLS is used. This flag is mainly for developers for testing purposes. We advise users to use the default value. Default is- True.
 
- Returns:
- glm
- Gaussian GLM object.