[Bioperl-l] Bio::FeatureIO::gff bug?

Chris Fields cjfields at uiuc.edu
Fri Sep 28 21:34:13 UTC 2007


On Sep 28, 2007, at 4:09 PM, Hilmar Lapp wrote:

>
> On Sep 28, 2007, at 12:04 PM, Chris Fields wrote:
>
>> In general I don't think SeqIO classes generates actual output
>> (like the GFF header information) in the constructor
>
> There's probably two reasons they don't (if really all of them
> don't): i) unless you explicitly test (how?) whether the file has
> been opened for writing, you actually don't know in the SeqIO
> constructor whether someone's going to write to the file or read from
> it. ii) off hand, I don't know of a sequence file format that would
> require a particular header being written just once.
>
> Though thinking about this, I start asking myself whether i) wouldn't
> also apply to FeatureIO (are we not reading gff too in this class?),
> and I'm wondering that there must  be a header (or at least an
> enclosing tag) for SeqIO XML formats - so how is that dealt with  
> there?
>
> 	-hilmar

Re: (i) and FeatureIO: I believe most FeatureIO classes read/write to/ 
from specific feature files (bed, gff, ptt, interpro, etc), which is  
one reason I thought everything I(nput) should go into next_feature 
(), everything O(utput) into write_feature().  The section writing  
the gff header info in _initialize() checks the file specifically for  
'>' prior to output; I think Sendu planned on changing that to use  
mode() instead.

Re: (ii): I'm not sure, actually; I wouldn't be surprised if XML  
output hasn't been tested very well.

If I could go to the Nov. GMOD meeting to help hammer out some of the  
GFF3/FeatureIO/SF::Annotated stuff I would, but I would be traveling  
on my own dime.  Maybe I'll see what I can come up with and stay at  
the no-tell motel...

chris



More information about the Bioperl-l mailing list