| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectir.eval.Experiment
public class Experiment
Contains methods for running evaluation experiments for information retrieval, specifically the generation of recall-precision curves for a given test corpus of query/relevant-documents pairs.
| Field Summary | |
|---|---|
|  java.io.File | corpusDirThe directory from which the indexed documents come. | 
|  java.io.File | outFileThe output file where final recall/precision result data is printed. | 
|  java.io.File | queryFileThe file with the list of queries and results to be tested. | 
| static double[] | RECALL_LEVELSThe standard recall levels for which we want to plot precision values | 
| Constructor Summary | |
|---|---|
| Experiment(java.io.File corpusDir,
           java.io.File queryFile,
           java.io.File outFile,
           short docType,
           boolean stem)Create an Experiment object for generating Recall/Precision curves | |
| Experiment(InvertedIndex index,
           java.io.File queryFile,
           java.io.File outFile)Create an Experiment object for generating Recall/Precision curves using a provided InvertedIndex | |
| Method Summary | |
|---|---|
| static void | main(java.lang.String[] args)Evaluate retrieval performance on a given query test corpus and generate a recall/precision graph. | 
|  void | makeRpCurve()Process and evaluate all queries and generate recall-precision curve | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
public static final double[] RECALL_LEVELS
public java.io.File corpusDir
public java.io.File queryFile
public java.io.File outFile
| Constructor Detail | 
|---|
public Experiment(java.io.File corpusDir,
                  java.io.File queryFile,
                  java.io.File outFile,
                  short docType,
                  boolean stem)
           throws java.io.IOException
corpusDir - The directory of files to index.queryFile - The file of query/relevant-docs pairs to evaluate.outFile - File for output precision/recall data.docType - The type of documents to index (See docType in DocumentIterator).stem - Whether tokens should be stemmed with Porter stemmer.
java.io.IOException
public Experiment(InvertedIndex index,
                  java.io.File queryFile,
                  java.io.File outFile)
           throws java.io.IOException
index - an InvertedIndex object that contains an indexed document collectionqueryFile - The file of query/relevant-docs pairs to evaluate.outFile - File for output precision/recall data.
java.io.IOException| Method Detail | 
|---|
public void makeRpCurve()
                 throws java.io.IOException
java.io.IOException
public static void main(java.lang.String[] args)
                 throws java.io.IOException
java.io.IOException| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||