|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.biojava.bio.seq.RNATools
public final class RNATools
Useful functionality for processing DNA and RNA sequences.
Method Summary | |
---|---|
static AtomicSymbol |
a()
|
static AtomicSymbol |
c()
|
static Symbol |
complement(Symbol sym)
Complement the symbol. |
static SymbolList |
complement(SymbolList list)
Retrieve a complement view of list. |
static ReversibleTranslationTable |
complementTable()
Get a translation table for complementing DNA symbols. |
static SymbolList |
createRNA(String rna)
Return a new RNA SymbolList for rna. |
static Sequence |
createRNASequence(String rna,
String name)
Return a new RNA Sequence for rna. |
static Symbol |
forIndex(int index)
Return the symbol for an index - compatible with index. |
static Symbol |
forSymbol(char token)
Retrieve the symbol for a symbol. |
static AtomicSymbol |
g()
|
static FiniteAlphabet |
getCodonAlphabet()
Gets the (RNA x RNA x RNA) Alphabet |
static ManyToOneTranslationTable |
getGeneticCode(int table_num)
Retrieve a TranslationTable by number. |
static ManyToOneTranslationTable |
getGeneticCode(String name)
Retrieve a TranslationTable by name. |
static Set |
getGeneticCodeNames()
Retrieve a Set containing the name of each genetic code. |
static FiniteAlphabet |
getRNA()
Return the RNA alphabet. |
static int |
index(Symbol sym)
Return an integer index for a symbol - compatible with forIndex. |
static Symbol |
n()
|
static SymbolList |
reverseComplement(SymbolList list)
Retrieve a reverse-complement view of list. |
static SymbolList |
transcribe(SymbolList list)
Deprecated. The naming of this method is confusing and inconsistent use either DNATools.toRNA(SymbolList list) or DNATools.transcribeToRNA(SymbolList list) depending on the desired behaivour. |
static ReversibleTranslationTable |
transcriptionTable()
Get a translation table for converting DNA to RNA. |
static SymbolList |
translate(SymbolList syms)
Translate RNA into protein (with termination symbols). |
static AtomicSymbol |
u()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static AtomicSymbol a()
public static AtomicSymbol g()
public static AtomicSymbol c()
public static AtomicSymbol u()
public static Symbol n()
public static FiniteAlphabet getRNA()
public static FiniteAlphabet getCodonAlphabet()
public static SymbolList createRNA(String rna) throws IllegalSymbolException
rna
- a String to parse into RNA
IllegalSymbolException
- if rna contains
any non-RNA characterspublic static Sequence createRNASequence(String rna, String name) throws IllegalSymbolException
rna
- a String to parse into RNAname
- a String to use as the name
IllegalSymbolException
- if rna contains
any non-DNA characterspublic static int index(Symbol sym) throws IllegalSymbolException
The index for a symbol is stable across virtual machines & invocations.
sym
- the Symbol to index
IllegalSymbolException
- if sym is not a member of the DNA alphabetpublic static Symbol forIndex(int index) throws IndexOutOfBoundsException
The index for a symbol is stable accross virtual machines & invocations.
index
- the index to look up
IndexOutOfBoundsException
- if index is not between 0 and 3public static Symbol complement(Symbol sym) throws IllegalSymbolException
sym
- the symbol to complement
IllegalSymbolException
- if sym is not a member of the RNA alphabetpublic static Symbol forSymbol(char token) throws IllegalSymbolException
token
- the char to look up
IllegalSymbolException
- if the char is not a valid IUB code.public static SymbolList complement(SymbolList list) throws IllegalAlphabetException
list
- the SymbolList to complement
IllegalAlphabetException
- if list is not a complementable alphabetpublic static SymbolList reverseComplement(SymbolList list) throws IllegalAlphabetException
list
- the SymbolList to complement
IllegalAlphabetException
- if list is not a complementable alphabetpublic static SymbolList transcribe(SymbolList list) throws IllegalAlphabetException
list
- the SymbolList to transcribe
IllegalAlphabetException
- if the list is not DNApublic static ReversibleTranslationTable complementTable()
public static ReversibleTranslationTable transcriptionTable()
public static ManyToOneTranslationTable getGeneticCode(String name)
You can now get the reverse translation of the residue back to its (usually several) codons too.
public static ManyToOneTranslationTable getGeneticCode(int table_num)
IllegalArgumentException
- if there is no table with that number.public static Set getGeneticCodeNames()
public static SymbolList translate(SymbolList syms) throws IllegalAlphabetException
IllegalAlphabetException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |