pub struct Ridge { /* private fields */ }Expand description
Minimises ‖y - Xw - b‖² + α ‖w‖². The penalty shrinks the weights, trading a little bias for a
large drop in variance when features are correlated or samples are few. The intercept is never
penalised (data are centred internally). Solved in closed form through the regularised normal
equations (XᵀX + αI) w = Xᵀy, which are always well posed for α > 0.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Ridge
impl RefUnwindSafe for Ridge
impl Send for Ridge
impl Sync for Ridge
impl Unpin for Ridge
impl UnsafeUnpin for Ridge
impl UnwindSafe for Ridge
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more