Class Classifier

java.lang.Object
edu.msu.cme.rdp.classifier.Classifier

public class Classifier extends Object
This is the class to do the classification.
  • Field Details

  • Method Details

    • getTrainRank

      public String getTrainRank()
    • classify

      public ClassificationResult classify(edu.msu.cme.rdp.readseq.readers.Sequence seq) throws IOException
      Takes a query sequence, returns the classification result. For each query sequence, first assign it to a genus node using all the words for calculation. Then randomly chooses one-eighth of the all overlapping words in the query to calculate the joint probability. The number of times a genus was selected out of the number of bootstrap trials was used as an estimate of confidence in the assignment to that genus.
      Throws:
      ShortSequenceException - if the sequence length is less than the minimum sequence length.
      IOException
    • classify

    • classify

      public ClassificationResult classify(ClassifierSequence seq, int min_bootstrap_words)
      Takes a query sequence, returns the classification result. For each query sequence, first assign it to a genus node using all the words for calculation. Then randomly chooses one-eighth of the all overlapping words in the query to calculate the joint probability. The number of times a genus was selected out of the number of bootstrap trials was used as an estimate of confidence in the assignment to that genus.
      Throws:
      ShortSequenceException - if the sequence length is less than the minimum sequence length.
    • addConfidence

      public void addConfidence(HierarchyTree node, HashMap map)
      increase the count of the RankAssignment in the map if match that node or any ancestor of that node.
      Parameters:
      node -
      map -