[BioPython] save or display fasta format
Sebastian Bassi
sbassi at asalup.org
Thu Dec 18 07:37:11 EST 2003
Hello,
When I parse a FASTA file I get the title and the sequence, and that's
OK. But sometimes I want to save a FASTA record to a file or display it
in the screen. The problem is that the sequences are printed as one line
(it is a string after all).
I'd like to know if there is an easy way to display them formated (70
columns per line for example).
Here is a representation of what I get:
>title
secuence_very_long_NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN
And that is what I want:
>title
secuence_properly_formated_NNNNNNNNNNNNNNNNNNN
NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN
NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN
(this size is fictional, but you get the idea!).
--
Best regards,
//=\ Sebastian Bassi - Diplomado en Ciencia y Tecnologia, UNQ //=\
\=// IT Manager Advanta Seeds - Balcarce Research Center - \=//
//=\ Pro secretario ASALUP - www.asalup.org - PGP key available //=\
\=// E-mail: sbassi at genesdigitales.com - ICQ UIN: 3356556 - \=//
http://Bioinformatica.info
More information about the BioPython
mailing list