Documentation of 'ca.pfv.spmf.algorithms.sequentialpatterns.clospan_AGP.AlgoCloSpan' Java class
AlgoCloSpan
ca.pfv.spmf.algorithms.sequentialpatterns.clospan_AGP

Class AlgoCloSpan



  • public class AlgoCloSpan
    extends java.lang.Object
    This is an implementation of the CloSpan algorithm. CloSpan was proposed by X. Yan et al. 2003.

    NOTE: This implementation saves the pattern to a file as soon as they are found or can keep the pattern into memory if no output path is provided by the user.
    • Constructor Summary

      Constructors 
      Constructor and Description
      AlgoCloSpan(double minSupRelative, AbstractionCreator creator, boolean findClosedPatterns, boolean executePruningMethods)
      Standard constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void clear()
      It clears all the attributes of AlgoPrefixSpan class
      double getAbsoluteMinSupport()
      It gets the absolute minimum support, i.e.
      int getNumberOfFrequentPatterns() 
      long getRunningTime()
      It gets the total time spent by the algoritm in its execution.
      java.lang.String printStatistics()
      Method to get the outlined information about the search for frequent sequences by means of CloSpan algorithm s a string
      void runAlgorithm(SequenceDatabase database, boolean keepPatterns, boolean verbose, java.lang.String outputFilePath)
      Method that starts the execution of the algorithm.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AlgoCloSpan

        public AlgoCloSpan(double minSupRelative,
                           AbstractionCreator creator,
                           boolean findClosedPatterns,
                           boolean executePruningMethods)
        Standard constructor. It takes the relative minimum support threshold (from 1 up to 0) and an abstraction creator
        Parameters:
        minSupRelative - the relative minimum support threshold
        creator - the abstraction creator
        findClosedPatterns - flag to indicate if we are interesting in only finding the closed sequences
    • Method Detail

      • runAlgorithm

        public void runAlgorithm(SequenceDatabase database,
                                 boolean keepPatterns,
                                 boolean verbose,
                                 java.lang.String outputFilePath)
                          throws java.io.IOException
        Method that starts the execution of the algorithm.
        Parameters:
        database - The original database in which we apply PrefixSpan
        keepPatterns - Flag indicating if the user want to keep the frequent patterns or he just want the amount of them
        verbose - Flag for debugging purposes
        outputFilePath - Path pointing out to the file where the output, composed of frequent patterns, has to be kept. If, conversely, this parameter is null, we understand that the user wants the output in the main memory
        Throws:
        java.io.IOException
      • printStatistics

        public java.lang.String printStatistics()
        Method to get the outlined information about the search for frequent sequences by means of CloSpan algorithm s a string
        Returns:
        a string containing this information
      • getNumberOfFrequentPatterns

        public int getNumberOfFrequentPatterns()
      • getRunningTime

        public long getRunningTime()
        It gets the total time spent by the algoritm in its execution.
        Returns:
        the time
      • getAbsoluteMinSupport

        public double getAbsoluteMinSupport()
        It gets the absolute minimum support, i.e. the minimum number of database sequences where a pattern has to appear
        Returns:
        the minimum support
      • clear

        public void clear()
        It clears all the attributes of AlgoPrefixSpan class

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.