Class FirstNEigenPairFilter

  • All Implemented Interfaces:
    EigenPairFilter

    @Title("First n Eigenpair filter")
    @Description("Sorts the eigenpairs in decending order of their eigenvalues and marks the first n eigenpairs as strong eigenpairs.")
    public class FirstNEigenPairFilter
    extends java.lang.Object
    implements EigenPairFilter
    The FirstNEigenPairFilter marks the n highest eigenpairs as strong eigenpairs, where n is a user specified number.
    Since:
    0.1
    Author:
    Elke Achtert
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  FirstNEigenPairFilter.Par
      Parameterization class.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private int n
      The threshold for strong eigenvectors: n eigenvectors with the n highest eigenvalues are marked as strong eigenvectors.
    • 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.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • n

        private int n
        The threshold for strong eigenvectors: n eigenvectors with the n highest eigenvalues are marked as strong eigenvectors.
    • Constructor Detail

      • FirstNEigenPairFilter

        public FirstNEigenPairFilter​(int n)
        Constructor.
        Parameters:
        n -
    • 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 interface EigenPairFilter
        Parameters:
        eigenValues - the array of eigenvalues, must be sorted descending
        Returns:
        the number of eigenvectors to keep