[Bioperl-l] Passing/Storing "Bio::SeqIO" object to a function

Chris Fields cjfields at illinois.edu
Thu Jun 24 18:47:26 UTC 2010


On Jun 24, 2010, at 1:28 PM, Abhishek Pratap wrote:

> Thanks everyone for your input. I have the script working.
> 
> Chris : Not sure what is the rationale, write_seq and next_seq has different
> key names in the hash ref( eg . 'display_id' and '-id') . This could
> possibly cause conflicts in future development.

The '-id' constructor argument (which is terribly non-specific) defaults to setting the display_id, as this is the most commonly used one.  Frankly, if it were up to me I would either die/warn with the -id parameter ('Error: Use a more specific ID type; defaulting to display_id') and defer as is, but that breaks API at the moment.  

This behavior is also the default in the older FASTQ parser as well as others (FASTA I believe), so it is retained for consistency.

> Also just wondering why
> currently only Bio:SeqIO:Quality object works with write_seq.

For FASTQ format, that would be the only one that would make sense (why output something with no quality information).  Unless I'm missing something, that's a feature, not a bug.

> -Abhi

chris



More information about the Bioperl-l mailing list