pal.alignment
Class CodonAlignment
java.lang.Object
|
+--pal.alignment.AbstractAlignment
|
+--pal.alignment.CodonAlignment
- All Implemented Interfaces:
- Alignment, IdGroup, Report, java.io.Serializable
- public class CodonAlignment
- extends AbstractAlignment
generates an codon alignment from a nucleotide alignment. Is designed to
translate from nucleotide alignments that do not have gaps. Codons that include
one or more gaps will be translated as a '?' (an UNKNOWN_CHARACTER).
- See Also:
- Serialized Form
Method Summary |
char |
getData(int seq,
int site)
sequence alignment at (sequence, site) |
Methods inherited from class pal.alignment.AbstractAlignment |
getAlignedSequenceString, getDataType, getFrequency, getIdCount, getIdentifier, getLength, getSequenceCount, getSiteCount, getStates, guessDataType, isGap, report, setDataType, setFrequency, setIdentifier, toString, whichIdNumber |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
DEFAULT_CODON_TRANSLATOR
public static final GeneralizedCodons DEFAULT_CODON_TRANSLATOR
CodonAlignment
public CodonAlignment(Alignment raw)
- Constructs an CodonAlignment from a given alignment
(which should be a nucleotide alignment), from codon position 0.
- Parameters:
raw
- original alignmentif
- a codon contains a gap or uses non nucleotide
characters resulting amino acid will be marked as a '?'
CodonAlignment
public CodonAlignment(Alignment raw,
int startingCodonPosition)
- Constructor
- Parameters:
raw
- original alignmentstartingCodonPosition
- - the starting codon position (0,1,2)if
- a codon contains a gap or uses non nucleotide characters
resulting amino acid will be marked as a '?'
CodonAlignment
public CodonAlignment(Alignment raw,
int startingCodonPosition,
GeneralizedCodons trans)
- Constructor
- Parameters:
raw
- original alignmentstartingCodonPosition
- - the starting codon position (0,1,2)trans
- - the translator (DataType) to use to convert nucleotides to amino acidsif
- a codon contains a gap or uses non nucleotide
characters resulting amino acid will be marked as a '?'
getData
public char getData(int seq,
int site)
- sequence alignment at (sequence, site)
- Overrides:
getData
in class AbstractAlignment