Class: CodonTable

CodonTable

This class contains all the codon table definitions and has the ability to translate DNA seqeunces to protein.

new CodonTable(geneticCodeID)

Create a new codon table

Name Type Description
geneticCodeID Number

ID for the genetic code (e.g. 1 for 'Standard' code)

Members

staticCodonTable.availableGeneticCodeIDs

Return array of all the available genetic code IDs

staticCodonTable.definitions

Returns all the available codon table definitions

codons

Return a list of the 64 codons, sorted in the following order: T, C, A, G

geneticCodeID

Return the genetic code for this codon table

name

Return the name for this codon table

starts

Return the start codons for this codon table

stops

Return the stop codons for this codon table

table

Return the table for this codon table

Methods

toString(){String}

Return the class name as a string.

Returns:
Type Description
String
  • 'CodonTable'

translate(seq, startCodon)

Translate a sequence using this codon table

Name Type Description
seq String

The sequence to translate

startCodon Number

Position (bp) of the first codon