jebl.evolution.parsimony
Interface ParsimonyCriterion

All Known Implementing Classes:
FitchParsimony

public interface ParsimonyCriterion

Author:
rambaut, Alexei Drummond Date: Jun 20, 2005 Time: 4:56:34 PM

Method Summary
 double getScore(Tree tree)
          Calculates the minimum number of steps for the parsimony reconstruction for the given tree.
 double[] getSiteScores(Tree tree)
          Calculates the minimum number of steps for the parsimony reconstruction for the given tree.
 State[] getStates(Tree tree, Node node)
          Returns the reconstructed character states for a given node in the tree.
 

Method Detail

getSiteScores

double[] getSiteScores(Tree tree)
Calculates the minimum number of steps for the parsimony reconstruction for the given tree. It is expected that the implementation's constructor will be set up with the characters so that repeated calls can be made to this function to evaluate different trees.

Parameters:
tree - a tree object to reconstruct the characters on
Returns:
an array containing the parsimony score for each site

getScore

double getScore(Tree tree)
Calculates the minimum number of steps for the parsimony reconstruction for the given tree. It is expected that the implementation's constructor will be set up with the characters so that repeated calls can be made to this function to evaluate different trees.

Parameters:
tree - a tree object to reconstruct the characters on
Returns:
the total score

getStates

State[] getStates(Tree tree,
                  Node node)
Returns the reconstructed character states for a given node in the tree.

Parameters:
tree - a tree object to reconstruct the characters on
node - the node of the tree
Returns:
an array containing the reconstructed states for this node