pub trait SupervisedEstimator<X, Y, P>: Predictor<X, Y> {
// Required methods
fn new() -> Self;
fn fit(x: &X, y: &Y, parameters: P) -> Result<Self, Failed>
where Self: Sized,
P: Clone;
}
Expand description
An estimator for supervised learning, that provides method fit
to learn from data and training values
Required Methods§
Sourcefn new() -> Self
fn new() -> Self
Empty constructor, instantiate an empty estimator. Object is dropped as soon as fit()
is called.
used to pass around the correct fit()
implementation.
by calling ::fit()
. mostly used to be used with model_selection::cross_validate(...)
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.