mulan.evaluation.measure
Class LabelBasedAUC

java.lang.Object
  extended by mulan.evaluation.measure.MeasureBase
      extended by mulan.evaluation.measure.ConfidenceMeasureBase
          extended by mulan.evaluation.measure.LabelBasedAUC
All Implemented Interfaces:
Serializable, Measure
Direct Known Subclasses:
MacroAUC, MicroAUC

public abstract class LabelBasedAUC
extends ConfidenceMeasureBase

Implementation of the label-based macro precision measure.

Version:
2012.07.17
Author:
Grigorios Tsoumakas
See Also:
Serialized Form

Field Summary
protected  FastVector all_Predictions
          The predictions for all labels
protected  FastVector[] m_Predictions
          The predictions for each label
protected  int numOfLabels
          The number of labels
 
Constructor Summary
LabelBasedAUC(int numOfLabels)
          Creates a new instance of this class
 
Method Summary
 double getIdealValue()
          Gets an 'ideal' value of a measure.
 void reset()
          Resets the cumulated measure value, so the process of computation can be started from beginning (e.g. for a new series of outputs from learning task).
protected  void updateConfidence(double[] confidences, boolean[] truth)
          Updates the measure for a new example
 
Methods inherited from class mulan.evaluation.measure.ConfidenceMeasureBase
updateInternal
 
Methods inherited from class mulan.evaluation.measure.MeasureBase
makeCopy, toString, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface mulan.evaluation.measure.Measure
getName, getValue
 

Field Detail

numOfLabels

protected int numOfLabels
The number of labels


m_Predictions

protected FastVector[] m_Predictions
The predictions for each label


all_Predictions

protected FastVector all_Predictions
The predictions for all labels

Constructor Detail

LabelBasedAUC

public LabelBasedAUC(int numOfLabels)
Creates a new instance of this class

Parameters:
numOfLabels - the number of labels
Method Detail

reset

public void reset()
Description copied from interface: Measure
Resets the cumulated measure value, so the process of computation can be started from beginning (e.g. for a new series of outputs from learning task).


getIdealValue

public double getIdealValue()
Description copied from interface: Measure
Gets an 'ideal' value of a measure. The 'ideal' means, that the value represents the best achievable performance of a learner for an prediction of a multi-label task and associated true labels.

Returns:
the ideal value

updateConfidence

protected void updateConfidence(double[] confidences,
                                boolean[] truth)
Description copied from class: ConfidenceMeasureBase
Updates the measure for a new example

Specified by:
updateConfidence in class ConfidenceMeasureBase
Parameters:
confidences - the confidences output by the learner for the example
truth - the ground truth of the example