hhreco.classification
Class Classification

java.lang.Object
  extended byhhreco.classification.Classification

public class Classification
extends java.lang.Object

Data structure for storing a list of classifer type and confidence value pairs in the order of descending confidence values.

During classification, an example is compared to each classifier which in turn generates a value indicating how confident it thinks that the example belongs in the class. This value is called the confidence value. A classification contains a list of classifiers along with their corresponding confidence values for the example.


Constructor Summary
Classification(java.lang.String[] types, double[] confidences)
          Construct a classification with no types.
 
Method Summary
 double getConfidence(int i)
          Return the i'th confidence.
 double getHighestConfidence()
          Return the highest confidence value.
 java.lang.String getHighestConfidenceType()
          Return the highest confidence type.
 java.lang.String getType(int i)
          Return the i'th type.
 int getTypeCount()
          Return the number of types in this classification.
 java.lang.String toString()
          Return a string representation of this classification consisting of type and confidence pairs.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Classification

public Classification(java.lang.String[] types,
                      double[] confidences)
Construct a classification with no types.

Method Detail

getHighestConfidence

public double getHighestConfidence()
Return the highest confidence value.


getHighestConfidenceType

public java.lang.String getHighestConfidenceType()
Return the highest confidence type.


getTypeCount

public int getTypeCount()
Return the number of types in this classification.


getType

public java.lang.String getType(int i)
Return the i'th type.


getConfidence

public double getConfidence(int i)
Return the i'th confidence.


toString

public java.lang.String toString()
Return a string representation of this classification consisting of type and confidence pairs.