[Biopython-dev] SeqIO and qual: Question about reading and writing qual files

Sebastian Bassi sbassi at clubdelarazon.org
Tue Mar 24 14:59:51 UTC 2009


On Tue, Mar 24, 2009 at 6:49 AM, Peter <biopython at maubp.freeserve.co.uk> wrote:
> Whose seqclean script are you using?  If it doesn't output the trimmed
> qual file, can it work with FASTQ output instead?

I am using the seqclean found here:
http://compbio.dfci.harvard.edu/tgi/software/
I doesn't output a trimmed qual file because seqclean accepts only
fasta as input. Oh, wait!!!. Looking at my seqclean directory I found
a cln2qual script. So I looked at the README to see what is it, and I
found:

"If after seqclean one needs to trim the corresponding quality values too,
according to the new coordinates or trash codes found by seqclean, the
utility script "cln2qual" is included (see the usage message). It expects
a fasta-like file containing space delimited quality values for each nucleotide
of the original sequences. It should be run after the seqclean, as it parses the
trimming ("clear range") coordinates and trash codes from the cleaning report
and applies them to the quality records."

So this utility does what I was about to do with Biopython.

But anyway, regarding this:

> This was one area of the new SeqRecord slicing I was a little unsure
> about - slicing a qual file's SeqRecord (or any SeqRecord with a None
> for the sequence).  I hadn't done anything about it immediately as I
> couldn't think of a use case for it - so that's solved ;)
> One solution would be to introduce an UnknownSeq object, which
....

I agree with the need of an UnknownSeq object for modify the size of
the qual file.

Best,
SB.



More information about the Biopython-dev mailing list