[Biojava-l] Using Annotation to Model a Tree Hierarchy

Ron Kuhn rkuhn@Cellomics.com
Wed, 17 Oct 2001 16:05:12 -0400


Biojava,
I solved the problem that I mentioned previously where the Genbank and
Swissprot flat file parsers utilized one SimpleAnnotation object to hold all
the references information about a sequence. The problem is that there is no
way to relate the title and authors values back to the parent references.

To solve the problem, I stored all the reference information in a separate
SimpleAnnotation and added it to the root annotation. It states in the
biojava docs that Annotations may contain keys that have Annotations as
values to model hierarchical data. For Genbank, the REFERENCE key
corresponds to an Annotation or an array of Annotations with the child
REFERENCE keys (i.e. AUTHORS, TITLE, etc.) stored in the child Annotation.
The same model exists for the Swissprot RN key. I had to make changes to the
SwissprotProcessor.java and GenbankProcessor.java files. What do you
think???

Ron Kuhn