Class PercentageEigenPairFilter
- java.lang.Object
-
- elki.math.linearalgebra.pca.filter.PercentageEigenPairFilter
-
- All Implemented Interfaces:
EigenPairFilter
@Title("Percentage based Eigenpair filter") @Description("Sorts the eigenpairs in decending order of their eigenvalues and returns the first eigenpairs, whose sum of eigenvalues is higher than the given percentage of the sum of all eigenvalues.") public class PercentageEigenPairFilter extends java.lang.Object implements EigenPairFilter
The PercentageEigenPairFilter sorts the eigenpairs in descending order of their eigenvalues and marks the first eigenpairs, whose sum of eigenvalues is higher than the given percentage of the sum of all eigenvalues as strong eigenpairs.- Since:
- 0.1
- Author:
- Elke Achtert
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
PercentageEigenPairFilter.Par
Parameterization class.
-
Field Summary
Fields Modifier and Type Field Description private double
alpha
The threshold for strong eigenvectors: the strong eigenvectors explain a portion of at least alpha of the total variance.static double
DEFAULT_ALPHA
The default value for alpha.-
Fields inherited from interface elki.math.linearalgebra.pca.filter.EigenPairFilter
PCA_EIGENPAIR_FILTER
-
-
Constructor Summary
Constructors Constructor Description PercentageEigenPairFilter(double alpha)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
filter(double[] eigenValues)
Filters the specified eigenvalues into strong and weak eigenvalues, where strong eigenvalues have high variance and weak eigenvalues have small variance.
-
-
-
Field Detail
-
DEFAULT_ALPHA
public static final double DEFAULT_ALPHA
The default value for alpha.- See Also:
- Constant Field Values
-
alpha
private double alpha
The threshold for strong eigenvectors: the strong eigenvectors explain a portion of at least alpha of the total variance.
-
-
Method Detail
-
filter
public int filter(double[] eigenValues)
Description copied from interface:EigenPairFilter
Filters the specified eigenvalues into strong and weak eigenvalues, where strong eigenvalues have high variance and weak eigenvalues have small variance.- Specified by:
filter
in interfaceEigenPairFilter
- Parameters:
eigenValues
- the array of eigenvalues, must be sorted descending- Returns:
- the number of eigenvectors to keep
-
-