Struct linfa_linear::TweedieRegressorParams
source · pub struct TweedieRegressorParams<F>(/* private fields */);
Expand description
The set of hyperparameters that can be specified for the execution of the Tweedie Regressor.
Implementations§
source§impl<F: Float> TweedieRegressorParams<F>
impl<F: Float> TweedieRegressorParams<F>
pub fn new() -> Self
sourcepub fn alpha(self, alpha: F) -> Self
pub fn alpha(self, alpha: F) -> Self
Constant that multiplies with the penalty term and thus determines the
regularization strenght. alpha
set to 0 is equivalent to unpenalized GLM.
sourcepub fn fit_intercept(self, fit_intercept: bool) -> Self
pub fn fit_intercept(self, fit_intercept: bool) -> Self
Specifies whether a bias or intercept should be added to the model
Trait Implementations§
source§impl<F: Clone> Clone for TweedieRegressorParams<F>
impl<F: Clone> Clone for TweedieRegressorParams<F>
source§fn clone(&self) -> TweedieRegressorParams<F>
fn clone(&self) -> TweedieRegressorParams<F>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<F: Debug> Debug for TweedieRegressorParams<F>
impl<F: Debug> Debug for TweedieRegressorParams<F>
source§impl<F: Float> Default for TweedieRegressorParams<F>
impl<F: Float> Default for TweedieRegressorParams<F>
source§impl<F: Float> ParamGuard for TweedieRegressorParams<F>
impl<F: Float> ParamGuard for TweedieRegressorParams<F>
§type Checked = TweedieRegressorValidParams<F>
type Checked = TweedieRegressorValidParams<F>
The checked hyperparameters
§type Error = LinearError<F>
type Error = LinearError<F>
Error type resulting from failed hyperparameter checking
source§fn check_ref(&self) -> Result<&Self::Checked, Self::Error>
fn check_ref(&self) -> Result<&Self::Checked, Self::Error>
Checks the hyperparameters and returns a reference to the checked hyperparameters if
successful
source§fn check(self) -> Result<Self::Checked, Self::Error>
fn check(self) -> Result<Self::Checked, Self::Error>
Checks the hyperparameters and returns the checked hyperparameters if successful
source§fn check_unwrap(self) -> Self::Checkedwhere
Self: Sized,
fn check_unwrap(self) -> Self::Checkedwhere
Self: Sized,
Calls
check()
and unwraps the resultsource§impl<F: PartialEq> PartialEq for TweedieRegressorParams<F>
impl<F: PartialEq> PartialEq for TweedieRegressorParams<F>
source§fn eq(&self, other: &TweedieRegressorParams<F>) -> bool
fn eq(&self, other: &TweedieRegressorParams<F>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl<F> StructuralPartialEq for TweedieRegressorParams<F>
Auto Trait Implementations§
impl<F> RefUnwindSafe for TweedieRegressorParams<F>where
F: RefUnwindSafe,
impl<F> Send for TweedieRegressorParams<F>where
F: Send,
impl<F> Sync for TweedieRegressorParams<F>where
F: Sync,
impl<F> Unpin for TweedieRegressorParams<F>where
F: Unpin,
impl<F> UnwindSafe for TweedieRegressorParams<F>where
F: UnwindSafe,
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