[Biopython-dev] Bio.Seq: implementing of translation of gapped sequences

Carlos Peña mycalesis at gmail.com
Tue Nov 3 08:26:06 UTC 2015


Hi all,


I have prepared a pull request to try implementing the translation of
gapped sequences (thanks Peter for guidelines!).

The code will infer the gap character from the Seq object's given alphabet.
If the alphabet is not present if can optionally accept a gap character,
then it will return a protein sequence with gaps, otherwise it will raise a
Translation error.

At least for me, the change will allow simplify the code of my projects.
However, this implementation might bite you if you are expecting a
TranslationError from trying to translate a gapped sequence. Instead you
will get back a gapped protein sequence (if you gap consists of dashes "-").

Is this change desirable for the Biopython project? I noticed that the
scikit-bio project does not implement gapped translations:
https://github.com/biocore/scikit-bio but I don't know why.


cheers


carlos


Dr. Carlos Peña
Laboratory of Genetics
Department of Biology
University of Turku
20014 Turku
FINLAND

* Associate Editor: Revista peruana de Biología
http://is.gd/TwbW

* The Nymphalidae Systematics Group
http://nymphalidae.utu.fi/db.php
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.open-bio.org/pipermail/biopython-dev/attachments/20151103/00a1e617/attachment.html>


More information about the Biopython-dev mailing list