pub struct PCA { /* private fields */ }
Expand description

Principal Component Analysis

  • PCA uses rulinalg SVD which is experimental (not yet work for large data)

Implementations

Constructs untrained PCA model.

Parameters
  • n : number of principal components
  • center : flag whether centering inputs to be specified.
Examples
use rusty_machine::learning::pca::PCA;

let model = PCA::new(3, true);

Returns principal components (matrix which contains eigenvectors as columns)

Trait Implementations

Formats the value using the given formatter. Read more

The default PCA.

Parameters:

  • n = None (keep all components)
  • center = true

Examples

use rusty_machine::learning::pca::PCA;

let model = PCA::default();
Returns the “default value” for a type. Read more

Train the model and predict the model output from new data.

Predict output from inputs.
Train the model using inputs.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.