Class Pca
java.lang.Object
ai.beestream.jitnn.ml.Pca
Principal component analysis from the eigendecomposition of the covariance matrix, after
scikit-learn's PCA: components as rows, ordered by explained variance, each signed so that its
largest-magnitude entry is positive (scikit-learn's svd_flip convention).
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionThe components [k, d].float[]The variance explained by each component.float[]The fraction of the total variance explained by each component.Fits samples x [n, features].Back from the projection to the feature space.Projection [n, k] of x onto the components.
-
Constructor Details
-
Pca
public Pca(int components) PCA keepingcomponentscomponents.
-
-
Method Details
-
fit
-
components
The components [k, d]. -
explainedVariance
public float[] explainedVariance()The variance explained by each component. -
explainedVarianceRatio
public float[] explainedVarianceRatio()The fraction of the total variance explained by each component. -
transform
-
inverseTransform
-