uk.ac.ebi.microarray.zooma.track
Class HypothesisRanking

java.lang.Object
  extended by uk.ac.ebi.microarray.zooma.track.HypothesisRanking
All Implemented Interfaces:
Information

public class HypothesisRanking
extends java.lang.Object
implements Information

An object that records ranking data for hypotheses. A HypothesisRankingTracker should re-rank hypotheses whenever data important to their ranking changes.

This class performs a general first cut at ranking hypotheses in order based on ontology and source information. The order of this ranking does not necessarily indicate the "best" hypothesis - you should formally test hypotheses against each other to see if this is true. Doing so may alter the rankings.

Author:
Tony Burdett

Constructor Summary
HypothesisRanking(SourceRanker sourceRanker, OntologyRanker ontologyRanker)
           
 
Method Summary
 void changed()
          Called whenever the ranking of hypotheses changes
protected  org.slf4j.Logger getLog()
           
protected  OntologyRanker getOntologyRanker()
           
 java.util.List<OntologyMappingHypothesis> getRankedHypotheses()
          Returns the list of hypotheses that have been ranked, in the order in which they rank.
protected  SourceRanker getSourceRanker()
           
 boolean rank(OntologyMappingHypothesis hypothesis)
          Rank, or rerank, the given hypothesis against all others
 boolean remove(OntologyMappingHypothesis hypothesis)
          Removes a previously ranked hypothesis from the rankings
 void setHypothesisRankingTracker(HypothesisRankingTracker tracker)
           
 void setOntologyRanker(OntologyRanker ontologyRanker)
           
 void setSourceRanker(SourceRanker sourceRanker)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HypothesisRanking

public HypothesisRanking(SourceRanker sourceRanker,
                         OntologyRanker ontologyRanker)
Method Detail

setSourceRanker

public void setSourceRanker(SourceRanker sourceRanker)

getSourceRanker

protected SourceRanker getSourceRanker()

setOntologyRanker

public void setOntologyRanker(OntologyRanker ontologyRanker)

getOntologyRanker

protected OntologyRanker getOntologyRanker()

setHypothesisRankingTracker

public void setHypothesisRankingTracker(HypothesisRankingTracker tracker)

getLog

protected org.slf4j.Logger getLog()

rank

public boolean rank(OntologyMappingHypothesis hypothesis)
Rank, or rerank, the given hypothesis against all others

Parameters:
hypothesis - the hypothesis to rank
Returns:
true if the ranking of this hypothesis was changed, or if this hypothesis wasn't previously ranked

remove

public boolean remove(OntologyMappingHypothesis hypothesis)
Removes a previously ranked hypothesis from the rankings

Parameters:
hypothesis - the hypothesis to remove
Returns:
true if this hypothesis was previously ranked and has been removed

getRankedHypotheses

public java.util.List<OntologyMappingHypothesis> getRankedHypotheses()
Returns the list of hypotheses that have been ranked, in the order in which they rank.

Returns:
the ranked list of hypotheses

changed

public void changed()
Called whenever the ranking of hypotheses changes

Specified by:
changed in interface Information


Copyright © 2010. All Rights Reserved.