[Biopython-dev] back_table in Bio.Data.CodonTable

Peter Cock p.j.a.cock at googlemail.com
Tue Jul 31 09:06:14 UTC 2012


On Mon, Jul 30, 2012 at 11:03 PM, Jeff Hussmann <jeff.hussmann at gmail.com> wrote:
> Hello all -
>
> Bio.Data.CodonTable currently has a variable back_table that provides
> a mapping from an amino acid to single (arbitrary?) codon that encodes
> the amino acid.

The current code (which I doubt is widely used) does pick an arbitrary
codon (using a sort to ensure this is consistent between Python versions).
As noted in the comments, there are more useful alternatives - but the
example of doing this on usage frequency is organism specific so
can't be hard coded.

> Is there any interest in adding a full_back_table (or some other
> suitable name) that would provide a mapping from an amino acid to a
> list of all codons that encode it? If so, I will submit a pull
> request. I have been using this myself for some projects on synonymous
> codon usage.

Something like that would be more useful - sure, do a pull request
from the current master branch.

See also past discussions about back translation of sequences, e.g.
http://lists.open-bio.org/pipermail/biopython/2012-April/007901.html

Peter



More information about the Biopython-dev mailing list