[Biopython-dev] Bio.SeqIO.convert function?

Peter biopython at maubp.freeserve.co.uk
Tue Jul 28 16:04:48 UTC 2009

On Tue, Jul 28, 2009 at 4:49 PM, Eric Talevich<eric.talevich at gmail.com> wrote:
> Hi Peter,
> On Tue, Jul 28, 2009 at 9:14 AM, Peter <biopython at maubp.freeserve.co.uk>wrote:
>> On Tue, Jul 28, 2009 at 12:19 PM, Peter<biopython at maubp.freeserve.co.uk>
>> wrote:
>> >
>> > Any thoughts? Would this all just make SeqIO too complicated?
>> >
>> The idea of the Bio.SeqIO.convert function was two fold:
>> (1) Syntactic sugar (and for this alone I wouldn't add it)
>> (2) Faster file format conversion (e.g. for scripts or pipelines)
> This would be nice if it was implemented in AlignIO and TreeIO, too. The
> naming is pretty intuitive, and the concept is general, so I don't think it
> makes the API any more difficult to understand. (Personally, I like having a
> sugary API to use inside ipython.)

OK - fair point. And yes, if we added it to Bio.SeqIO, it would make
sense to add a similar function to Bio.AlignIO and the nascent
Bio.TreeIO module too.

If combined with allowing filenames in place of handles, then yes, it makes
one line file conversion very convenient too. On the more general issue
of filenames versus handles, I think I'll reply on a new thread though...


More information about the Biopython-dev mailing list