Enum linfa_elasticnet::Error [−][src]
pub enum Error { NotEnoughSamples, IllConditioned, BaseCrate(Error), }
Variants
The input has not enough samples
The input is singular
BaseCrate(Error)
Trait Implementations
impl<F, D, T> Fit<ArrayBase<D, Dim<[usize; 2]>>, T, Error> for ElasticNetParams<F> where
F: Float + Lapack,
D: Data<Elem = F>,
T: AsTargets<Elem = F>,
[src]
impl<F, D, T> Fit<ArrayBase<D, Dim<[usize; 2]>>, T, Error> for ElasticNetParams<F> where
F: Float + Lapack,
D: Data<Elem = F>,
T: AsTargets<Elem = F>,
[src]type Object = ElasticNet<F>
fn fit(
&self,
dataset: &DatasetBase<ArrayBase<D, Ix2>, T>
) -> Result<Self::Object>
[src]
&self,
dataset: &DatasetBase<ArrayBase<D, Ix2>, T>
) -> Result<Self::Object>
Fit an elastic net model given a feature matrix x
and a target
variable y
.
The feature matrix x
must have shape (n_samples, n_features)
The target variable y
must have shape (n_samples)
Returns a FittedElasticNet
object which contains the fitted
parameters and can be used to predict
values of the target variable
for new feature values.
Auto Trait Implementations
impl RefUnwindSafe for Error
impl RefUnwindSafe for Error
impl UnwindSafe for Error
impl UnwindSafe for Error