[Bioperl-l] Annotation of features

Ewan Birney birney@ebi.ac.uk
Thu, 26 Sep 2002 09:22:19 +0100 (BST)


On Wed, 25 Sep 2002, Hilmar Lapp wrote:

> Currently the only annotation you can stick on SeqFeatureIs is
> tag/value pairs. This is orthogonal to SeqIs.
>
> I just realized that SeqFeature::Generic does have annotation(). I
> vote for propagating this method to the interface level.

We have a real push me/pull you situation here:


Some people make millions upon millions of features, and size and
implementation overhead is a big issue


Some people have things like genes which are almost as good as any other
annotatable thing.


What about officially allowing mix-ins - an implementation can be both a
SeqFeatureI and a AnnotationI (ie, can annotation()) and clients can test
with ISA. What is the drawback of this?





>
> SeqFeatureI's tag/value annotation should be transparently the same
> as for SeqI. This means tag/value pairs should be annotated as
> Bio::Annotation::SimpleValue instances added to the
> AnnotationCollection.
>
> This may, however, create significant overhead when SeqFeatureIs are
> instantiated (every tag/value pair amounts to an object).
> Thoughts/comments?
>
> The problem could possibly be alleviated by writing an adaptor that
> adapts SeqFeatureI to AnnotationCollectionI, and annotation() would
> return an instance of that adaptor. In that case the implementation
> could make sure that you only incur the overhead once you actually
> request those values.
>
> I'd be glad to hear anyone's thoughts on this.
>
> 	-hilmar
>
> --
> -------------------------------------------------------------
> Hilmar Lapp                            email: lapp at gnf.org
> GNF, San Diego, Ca. 92121              phone: +1-858-812-1757
> -------------------------------------------------------------
>
> _______________________________________________
> Bioperl-l mailing list
> Bioperl-l@bioperl.org
> http://bioperl.org/mailman/listinfo/bioperl-l
>