jebl.evolution.alignments
Interface Pattern


public interface Pattern

An interface representing a list of states for a list of taxa.

Author:
Andrew Rambaut, Alexei Drummond

Method Summary
 int getLength()
           
 State getMostFrequentState()
          Returns the most frequent state in this pattern
 SequenceType getSequenceType()
           
 State getState(int index)
          Get the state for the ith taxon
 double getStateFrequency(State state)
          Returns the frequent of the given state in this pattern
 List<State> getStates()
           
 Set<State> getStateSet()
           
 List<Taxon> getTaxa()
           
 double getWeight()
          Get the weight of this pattern
 

Method Detail

getSequenceType

SequenceType getSequenceType()
Returns:
the data type of the states in this pattern.

getLength

int getLength()

getTaxa

List<Taxon> getTaxa()
Returns:
the list of taxa that the state values correspond to.

getState

State getState(int index)
Get the state for the ith taxon

Parameters:
index -
Returns:
the state

getStates

List<State> getStates()
Returns:
the list of state values of this pattern.

getStateSet

Set<State> getStateSet()
Returns:
the set of state values of this pattern.

getWeight

double getWeight()
Get the weight of this pattern

Returns:
the weight

getMostFrequentState

State getMostFrequentState()
Returns the most frequent state in this pattern

Returns:
the most frequent state

getStateFrequency

double getStateFrequency(State state)
Returns the frequent of the given state in this pattern

Parameters:
state -
Returns:
the frequency