[−][src]Trait ndarray_glm::link::Transform
Required methods
fn nat_param<F: Float>(lin_pred: Array1<F>) -> Array1<F>
The natural parameter(s) of the response distribution as a function of the linear predictor. For canonical link functions this is the identity. It must be monotonic, invertible, and twice-differentiable. For link function g and canonical link function g_0 it is equal to g_0 ( g^{-1}(lin_pred) ) .
fn d_nat_param<F: Float>(lin_pred: &Array1<F>) -> Array1<F>
The derivative of the transformation to the natural parameter. If it is zero in a region that the IRLS is in the algorithm may have difficulty converging.
Provided methods
fn adjust_errors_variance<F: Float>(
errors: Array1<F>,
variance: Array1<F>,
lin_pred: &Array1<F>
) -> (Array1<F>, Array1<F>)
errors: Array1<F>,
variance: Array1<F>,
lin_pred: &Array1<F>
) -> (Array1<F>, Array1<F>)
Adjust the error and variance terms of the likelihood function based on the first and second derivatives of the transformation. The adjustment is performed simultaneously. The linear predictor must be un-transformed, i.e. it must be X*beta without the transformation applied.
Implementors
impl Transform for Cloglog
[src]
fn nat_param<F: Float>(lin_pred: Array1<F>) -> Array1<F>
[src]
fn d_nat_param<F: Float>(lin_pred: &Array1<F>) -> Array1<F>
[src]
impl<T> Transform for T where
T: Canonical,
[src]
T: Canonical,
fn nat_param<F: Float>(lin_pred: Array1<F>) -> Array1<F>
[src]
By defintion this function is the identity function for canonical links.
fn d_nat_param<F: Float>(lin_pred: &Array1<F>) -> Array1<F>
[src]
fn adjust_errors_variance<F: Float>(
errors: Array1<F>,
variance: Array1<F>,
_lin_pred: &Array1<F>
) -> (Array1<F>, Array1<F>)
[src]
errors: Array1<F>,
variance: Array1<F>,
_lin_pred: &Array1<F>
) -> (Array1<F>, Array1<F>)
The canonical link function requires no transformation of the error and variance terms.