[BioPython] Sequence from Fasta

Stefanie Lück lueck at ipk-gatersleben.de
Tue Jul 1 07:40:38 UTC 2008


--> Peter wrote:
> from Bio import SeqIO
> handle = open("ls_orchid.fasta")
> for seq_record in SeqIO.parse(handle, "fasta") :
>    print seq_record.id
>    print seq_record.seq.tostring()
>    print len(seq_record.seq)
> handle.close()

This works! Thanks!

--> Giovanni wrote:
>Bioperl's SeqIO has support for a 'tab sequence format' which is
>similar to this[1].
>Maybe it could be useful in the future to add support for such a
>format in biopython.

It's a very good idea because I was suprised that it dosen't work. I 
excpected it.

Regards
Stefanie




More information about the Biopython mailing list