Package jebl.evolution.substmodel
Interface RateMatrix
- All Superinterfaces:
Cloneable,Serializable
- All Known Implementing Classes:
AbstractRateMatrix,AminoAcidModel,WAG
abstract base class for all rate matrices
- Version:
- $Id: RateMatrix.java 185 2006-01-23 23:03:18Z rambaut $
- Author:
- Korbinian Strimmer, Alexei Drummond, Matthew Goode
-
Method Summary
Modifier and TypeMethodDescriptionintdouble[]doublegetEquilibriumFrequency(int i) double[][]Get the data type of this rate matrixvoidgetTransitionProbabilities(double[][] probabilityStore) A utility method for speed, transfers trans prob information quickly into store.doublegetTransitionProbability(int fromState, int toState) voidsetDistance(double distance) Sets the distance (such as time/branch length) used when calculating the probabilities.
-
Method Details
-
getUniqueName
String getUniqueName()- Returns:
- a short unique human-readable identifier for this rate matrix.
-
getDimension
int getDimension()- Returns:
- the dimension of this rate matrix.
-
getEquilibriumFrequencies
double[] getEquilibriumFrequencies()- Returns:
- stationary frequencies (sum = 1.0)
-
getEquilibriumFrequency
double getEquilibriumFrequency(int i) - Returns:
- stationary frequency (sum = 1.0) for ith state Preferred method for infrequent use.
-
getSequenceType
SequenceType getSequenceType()Get the data type of this rate matrix -
getRelativeRates
double[][] getRelativeRates()- Returns:
- rate matrix (transition: from 1st index to 2nd index)
-
getTransitionProbability
double getTransitionProbability(int fromState, int toState) - Parameters:
fromState- The state from which we are startingtoState- The resulting state- Returns:
- the probability of going from one state to another given the current distance
-
getTransitionProbabilities
void getTransitionProbabilities(double[][] probabilityStore) A utility method for speed, transfers trans prob information quickly into store. -
setDistance
void setDistance(double distance) Sets the distance (such as time/branch length) used when calculating the probabilities. This method may well take the most time!
-