edu.cmu.minorthird.classify
Class TweakedLearner.TweakedClassifier

java.lang.Object
  extended by edu.cmu.minorthird.classify.BinaryClassifier
      extended by edu.cmu.minorthird.classify.TweakedLearner.TweakedClassifier
All Implemented Interfaces:
Classifier, Visible, java.io.Serializable
Enclosing class:
TweakedLearner

public static class TweakedLearner.TweakedClassifier
extends BinaryClassifier
implements java.io.Serializable, Visible

A Tweaked Classifier, with an optimization of the precision vs. recall Please note that this is an internal class of the TweakedLearner class. It is constructed and returned by the TweakedLearner, based on an original untweaked binary clasifer, and a threshold which was found to optimized precision vs. recall

Author:
Giora Unger Created on May 19, 2005
See Also:
Serialized Form

Field Summary
 
Fields inherited from class edu.cmu.minorthird.classify.BinaryClassifier
classifierLearner
 
Constructor Summary
TweakedLearner.TweakedClassifier(BinaryClassifier classifier, double threshold)
           
 
Method Summary
 java.lang.String explain(Instance instance)
          Return some string that 'explains' the classification
 Explanation getExplanation(Instance instance)
          Return an Explanation for the classification
 double score(Instance instance)
          Get the weight for an instance being in the positive class.
 Viewer toGUI()
          Create a view of this object
 
Methods inherited from class edu.cmu.minorthird.classify.BinaryClassifier
classification, getClassifierLearner, setClassifierLearner
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TweakedLearner.TweakedClassifier

public TweakedLearner.TweakedClassifier(BinaryClassifier classifier,
                                        double threshold)
Method Detail

score

public double score(Instance instance)
Description copied from class: BinaryClassifier
Get the weight for an instance being in the positive class.

Specified by:
score in class BinaryClassifier

toGUI

public Viewer toGUI()
Description copied from interface: Visible
Create a view of this object

Specified by:
toGUI in interface Visible

explain

public java.lang.String explain(Instance instance)
Description copied from interface: Classifier
Return some string that 'explains' the classification

Specified by:
explain in interface Classifier

getExplanation

public Explanation getExplanation(Instance instance)
Description copied from interface: Classifier
Return an Explanation for the classification

Specified by:
getExplanation in interface Classifier