Struct rusty_machine::data::transforms::minmax::MinMaxScaler
[−]
[src]
pub struct MinMaxScaler<T: Float> { /* fields omitted */ }
The MinMaxScaler
The MinMaxScaler
provides an implementation of Transformer
which allows us to transform the input data to have a new minimum
and maximum per column.
See the module description for more information.
Methods
impl<T: Float> MinMaxScaler<T>
[src]
fn new(min: T, max: T) -> MinMaxScaler<T>
Constructs a new MinMaxScaler with the specified scale.
Examples
use rusty_machine::data::transforms::{MinMaxScaler, Transformer}; // Constructs a new `MinMaxScaler` which will give the data // minimum `0` and maximum `2`. let transformer = MinMaxScaler::new(0.0, 2.0);
Trait Implementations
impl<T: Debug + Float> Debug for MinMaxScaler<T>
[src]
impl<T: Float> Default for MinMaxScaler<T>
[src]
Create a default MinMaxScaler
with minimum of 0
and
maximum of 1
.
fn default() -> MinMaxScaler<T>
Returns the "default value" for a type. Read more
impl<T: Float> Transformer<Matrix<T>> for MinMaxScaler<T>
[src]
fn fit(&mut self, inputs: &Matrix<T>) -> Result<(), Error>
Fit Transformer to input data, and stores the transformation in the Transformer
fn transform(&mut self, inputs: Matrix<T>) -> Result<Matrix<T>, Error>
Transforms the inputs and stores the transformation in the Transformer
impl<T: Float> Invertible<Matrix<T>> for MinMaxScaler<T>
[src]
fn inv_transform(&self, inputs: Matrix<T>) -> Result<Matrix<T>, Error>
Maps the inputs using the inverse of the fitted transform.