org.galagosearch.core.eval
Class SetRetrievalEvaluator

java.lang.Object
  extended by org.galagosearch.core.eval.SetRetrievalEvaluator

public class SetRetrievalEvaluator
extends java.lang.Object

Computes summary statistics over a set of queries.

Author:
Trevor Strohman

Constructor Summary
SetRetrievalEvaluator(java.util.Collection<RetrievalEvaluator> evaluators)
          Creates a new instance of SetRetrievalEvaluator
 
Method Summary
 java.util.Map<java.lang.String,java.lang.Double> evaluateAll(java.lang.String metric)
          Returns a Map containing a particular metric value for each query.
 double geometricMeanAveragePrecision()
          Returns the geometric mean of average precision values for all queries.
 java.util.Collection<RetrievalEvaluator> getEvaluators()
          Returns a collection of evaluators.
 double meanAveragePrecision()
          Returns the mean average precision; the mean of the average precision values for all queries.
 double meanBinaryPreference()
          Returns the mean of the binary preference values for all queries.
 double meanNormalizedDiscountedCumulativeGain()
          Returns the mean of the NDCG values for all queries.
 double meanNormalizedDiscountedCumulativeGain(int documentsRetrieved)
          Returns the mean of the NDCG values for all queries.
 double meanPrecision(int documentsRetrieved)
          Returns the mean of the precision values for all queries.
 double meanReciprocalRank()
          Returns the mean of the reciprocal rank values for all queries.
 double meanRPrecision()
          Returns the mean of the R-precision values for all queries.
 int numberRelevant()
          The total number of relevant documents to any of the queries.
 int numberRelevantRetrieved()
          The total number of relevant documents retrieved for any of the queries.
 int numberRetrieved()
          The number of documents retrieved for all queries.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SetRetrievalEvaluator

public SetRetrievalEvaluator(java.util.Collection<RetrievalEvaluator> evaluators)
Creates a new instance of SetRetrievalEvaluator

Method Detail

getEvaluators

public java.util.Collection<RetrievalEvaluator> getEvaluators()
Returns a collection of evaluators.


meanAveragePrecision

public double meanAveragePrecision()
Returns the mean average precision; the mean of the average precision values for all queries.


meanBinaryPreference

public double meanBinaryPreference()
Returns the mean of the binary preference values for all queries.


geometricMeanAveragePrecision

public double geometricMeanAveragePrecision()
Returns the geometric mean of average precision values for all queries.


meanPrecision

public double meanPrecision(int documentsRetrieved)
Returns the mean of the precision values for all queries.


meanReciprocalRank

public double meanReciprocalRank()
Returns the mean of the reciprocal rank values for all queries.


meanRPrecision

public double meanRPrecision()
Returns the mean of the R-precision values for all queries.


meanNormalizedDiscountedCumulativeGain

public double meanNormalizedDiscountedCumulativeGain()
Returns the mean of the NDCG values for all queries.


meanNormalizedDiscountedCumulativeGain

public double meanNormalizedDiscountedCumulativeGain(int documentsRetrieved)
Returns the mean of the NDCG values for all queries.


evaluateAll

public java.util.Map<java.lang.String,java.lang.Double> evaluateAll(java.lang.String metric)
                                                             throws java.lang.IllegalArgumentException
Returns a Map containing a particular metric value for each query. For instance, if metric == "averagePrecision", this returns a map where the keys are query identifiers and the values are the average precision metric evaluated for each query.

Throws:
java.lang.IllegalArgumentException

numberRetrieved

public int numberRetrieved()
The number of documents retrieved for all queries.


numberRelevant

public int numberRelevant()
The total number of relevant documents to any of the queries.


numberRelevantRetrieved

public int numberRelevantRetrieved()
The total number of relevant documents retrieved for any of the queries.



Copyright © 2009. All Rights Reserved.