[BioPython] Checked in Parsers for Phred and Ace files

Frank Kauff fkauff at duke.edu
Thu Jan 29 15:38:38 EST 2004


On Sun, 2004-01-25 at 19:22, Brad Chapman wrote:
> Hello all;
> Thanks to Frank Kauff's generous contributions, I've just checked
> parsers for Phred and Ace files (from the whole Phred/Phrap/Consed
> distribution).
> 
> They are checked in as:
> 
> Bio/Sequencing/Ace.py
> Bio/Sequencing/Phred.py
> 
> They work in the same way as standard Biopython parsers so you could
> get a Phred iterator and parser with:
> 
> from Bio.Sequencing import Phred
> 
> parser = Phred.RecordParser()
> iterator = Phred.Iterator(open("your_phred_file.phd"), parser)
> 
> while 1:
>     rec = iterator.next()
>     if not rec:
>         break
>     # do something with the record
> 
> The one caveat is that the Ace parser does not support RT, CT and WA 
> tags. But, it does do lots of other useful things and if you need
> these tags (or know more about them) feel free to provide patches
> adding them.

I couldn't stand a parser that's not completely doing its job,
especially when it's written by myself :-). So I added supprt for these
three tags. It seems to work fine - however, before I submit it, I'd
like to be sure that it complies to the specification of the ACE format.
The consed documentation is not really exact about many things - so does
anybody know where to find a more comprehensive descripion of the ace
format? Is there any?

Frank

> 
> I'd appreciate it if people who are using Phred and Ace files could
> test drive the code and make sure it works with their code. I'll try
> to get some phred and ace files from our own lab and add at least a
> quick test suite for them later this week.
> 
> Thanks to Frank for the contribution!
> Brad
> _______________________________________________
> BioPython mailing list  -  BioPython at biopython.org
> http://biopython.org/mailman/listinfo/biopython
-- 
Frank Kauff
Dept. of Biology
Duke University
Box 90338
Durham, NC 27708
USA

Phone 919-660-7382
Fax 919-660-7293



More information about the BioPython mailing list