jebl.evolution.sequences
Class Codons
java.lang.Object
jebl.evolution.sequences.Codons
public final class Codons
- extends Object
- Author:
- Andrew Rambaut, Alexei Drummond
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
NAME
public static final String NAME
- See Also:
- Constant Field Values
CANONICAL_STATE_COUNT
public static final int CANONICAL_STATE_COUNT
- See Also:
- Constant Field Values
STATE_COUNT
public static final int STATE_COUNT
- See Also:
- Constant Field Values
CANONICAL_STATES
public static final CodonState[] CANONICAL_STATES
STATES
public static final CodonState[] STATES
UNKNOWN_STATE
public static final CodonState UNKNOWN_STATE
GAP_STATE
public static final CodonState GAP_STATE
Codons
public Codons()
getStateCount
public static int getStateCount()
getStates
public static List<State> getStates()
getCanonicalStateCount
public static int getCanonicalStateCount()
getCanonicalStates
public static List<State> getCanonicalStates()
getState
public static CodonState getState(NucleotideState nucleotide1,
NucleotideState nucleotide2,
NucleotideState nucleotide3)
getState
public static CodonState getState(String code)
- Gets the state object for the given code. Returns null if the code is illegal.
- Parameters:
code
- a three-character string of nucleotides in uppercase
- Returns:
- the state
getState
public static CodonState getState(int index)
getUnknownState
public static CodonState getUnknownState()
getGapState
public static CodonState getGapState()
isUnknown
public static boolean isUnknown(CodonState state)
isGap
public static boolean isGap(CodonState state)
toNucleotides
public static NucleotideState[] toNucleotides(CodonState state)
toStateArray
public static CodonState[] toStateArray(String sequenceString)
toStateArray
public static CodonState[] toStateArray(byte[] indexArray)