[Biopython] Passing wrap parameter to FastaWriter using SeqIO.write
Eric Talevich
eric.talevich at gmail.com
Thu May 20 20:59:02 EDT 2010
On Wed, May 19, 2010 at 3:59 PM, Peter <biopython at maubp.freeserve.co.uk>wrote:
> On Wed, May 19, 2010 at 11:48 PM, Uri Laserson wrote:
> > I see that there is a wrap parameter for the FastaWriter object, but no
> way
> > to set it using the SeqIO.write() facility. What is the best way to
> > implement this? Perhaps we can do a matplotlib-style implementation,
> > where we just pass on some keyword arguments, and if it works it works?
>
> Hi Uri,
>
> We could in theory allow Bio.SeqIO.write() etc to accept arbitrary
> arguments and pass them on to the format specific code, but I'm
> uneasy about this. Documenting it would be hard - I think making
> you use the underlying module directly for fine control is clearer.
> For now you have to use the Bio.SeqIO.FastaIO module directly if
> you want to set any additional options like the line wrapping.
>
Hi Peter,
So, um, Bio.Phylo accepts arbitrary keyword arguments and passes them on to
the format-specific code.
http://github.com/etal/biopython/blob/phyloxml/Bio/Phylo/_io.py
I found it convenient during development and interactive use.
-Eric
More information about the Biopython
mailing list