mulan.evaluation.measure
Class LabelBasedFMeasure

java.lang.Object
  extended by mulan.evaluation.measure.MeasureBase
      extended by mulan.evaluation.measure.BipartitionMeasureBase
          extended by mulan.evaluation.measure.LabelBasedBipartitionMeasureBase
              extended by mulan.evaluation.measure.LabelBasedFMeasure
All Implemented Interfaces:
Serializable, Measure
Direct Known Subclasses:
MacroFMeasure, MicroFMeasure

public abstract class LabelBasedFMeasure
extends LabelBasedBipartitionMeasureBase

Base implementation of the label-based macro/micro f-measures.

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

Field Summary
protected  double beta
          the parameter for combining precision and recall
 
Fields inherited from class mulan.evaluation.measure.LabelBasedBipartitionMeasureBase
falseNegatives, falsePositives, numOfLabels, trueNegatives, truePositives
 
Constructor Summary
LabelBasedFMeasure(int numOfLabels)
          Constructs a new object with given number of labels
LabelBasedFMeasure(int numOfLabels, double beta)
          Constructs a new object with given number of labels and beta parameter
 
Method Summary
 double getIdealValue()
          Gets an 'ideal' value of a measure.
 
Methods inherited from class mulan.evaluation.measure.LabelBasedBipartitionMeasureBase
reset, updateBipartition
 
Methods inherited from class mulan.evaluation.measure.BipartitionMeasureBase
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

beta

protected final double beta
the parameter for combining precision and recall

Constructor Detail

LabelBasedFMeasure

public LabelBasedFMeasure(int numOfLabels)
Constructs a new object with given number of labels

Parameters:
numOfLabels - the number of labels

LabelBasedFMeasure

public LabelBasedFMeasure(int numOfLabels,
                          double beta)
Constructs a new object with given number of labels and beta parameter

Parameters:
numOfLabels - the number of labels
beta - the beta parameter
Method Detail

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