de.aitools.dm.clusterlabeling.validation.external
Class PreferencedMeasure

java.lang.Object
  extended by de.aitools.dm.clusterlabeling.validation.external.PreferencedMeasure
All Implemented Interfaces:
ExternalMeasure
Direct Known Subclasses:
MatchAtN, MeanAveragePrecision, MeanReciprocalRank, PrecisionAtN

public abstract class PreferencedMeasure
extends java.lang.Object
implements ExternalMeasure

Abstract extension of the ExternalMeasure-Interface. Including the setting of the preferences of the validation in the constructor via the MeasurePreferences-Struct.

Version:
$Id: PreferencedMeasure.java,v 1.1 2011/02/18 16:08:24 hoppe Exp $
Author:
johannes.kiesel(/\t)uni-weimar.de

Constructor Summary
PreferencedMeasure(MeasurePreferences preferences)
           
 
Method Summary
 double evalClusterLabels(java.lang.String[] clusterLabels)
          This will set the clusterLabels to be used on validation, most likely via setClusterLabels(clusterLabels) and the evaluate the pair referenceLabel - clusterLabels depending on the concrete implementation.
 double evalReferenceLabel(java.lang.String referenceLabel)
          This will set the referenceLabel to be used on validation, most likely via setReferenceLabel(referenceLabel) and the evaluate the pair referenceLabel - clusterLabels depending on the concrete implementation.
 java.lang.String[][] getClusterLabels()
           
 java.lang.String getReferenceLabel()
           
 void setClusterLabels(java.lang.String[] clusterLabels)
          This will set the clusterLabels to be used for Validation.
 void setReferenceLabel(java.lang.String referenceLabel)
          This will set the referenceLabel to be used on validation.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface de.aitools.dm.clusterlabeling.validation.external.ExternalMeasure
eval, evalAt
 

Constructor Detail

PreferencedMeasure

public PreferencedMeasure(MeasurePreferences preferences)
Method Detail

getReferenceLabel

public java.lang.String getReferenceLabel()

getClusterLabels

public java.lang.String[][] getClusterLabels()

setClusterLabels

public void setClusterLabels(java.lang.String[] clusterLabels)
Description copied from interface: ExternalMeasure
This will set the clusterLabels to be used for Validation. A clusterLabel is a automatically generated label, which to evaluate is the subject of the classes of this package.
More clusterLabels can be given.
The order will certainly be important.
Processing (creating synonyms/stemming/converting to lower case) will take place according to the concrete implementation of the interface.

Specified by:
setClusterLabels in interface ExternalMeasure
Parameters:
clusterLabels - generated labels for the cluster

setReferenceLabel

public void setReferenceLabel(java.lang.String referenceLabel)
Description copied from interface: ExternalMeasure
This will set the referenceLabel to be used on validation. A referenceLabel is a phrase created for extern evaluation. Depending on the measure, the closer a clusterLabel fits to the referenceLabel, the higher the score taken.
Processing (stemming/converting to lower case) will take place according to the concrete implementation of the interface.

Specified by:
setReferenceLabel in interface ExternalMeasure
Parameters:
referenceLabel - the best descriptive phrase for the cluster

evalClusterLabels

public double evalClusterLabels(java.lang.String[] clusterLabels)
Description copied from interface: ExternalMeasure
This will set the clusterLabels to be used on validation, most likely via setClusterLabels(clusterLabels) and the evaluate the pair referenceLabel - clusterLabels depending on the concrete implementation.
Attention: The return-value may vary significantly in its meaning depending on the implementation. Higher values should suggest closer pairs.

Specified by:
evalClusterLabels in interface ExternalMeasure
Parameters:
clusterLabels - generated labels for the cluster

evalReferenceLabel

public double evalReferenceLabel(java.lang.String referenceLabel)
Description copied from interface: ExternalMeasure
This will set the referenceLabel to be used on validation, most likely via setReferenceLabel(referenceLabel) and the evaluate the pair referenceLabel - clusterLabels depending on the concrete implementation.
Attention: The return-value may vary significantly in its meaning depending on the implementation. Higher values should suggest closer pairs.

Specified by:
evalReferenceLabel in interface ExternalMeasure
Parameters:
referenceLabel - the best descriptive phrase for the cluster