source: orange-bioinformatics/docs/reference-html/obiGO-slim-mapping.py @ 1662:427f1876f3e6

Revision 1662:427f1876f3e6, 467 bytes checked in by mitar, 2 years ago (diff)

Revamped documentation.

Line 
1import obiGO
2
3ontology = obiGO.Ontology()
4annotations = obiGO.Annotations("sgd", ontology=ontology)
5
6ontology.SetSlimsSubset("goslim_yeast")
7terms = annotations.GetAnnotatedTerms(["YGR270W", "YIL075C", "YDL007W"], directAnnotationOnly=True)
8slims = set()
9for term in terms:
10    print term
11    slims.update(ontology.GetSlimTerms(term))
12
13print "Genes: YGR270W, YIL075C and YDL007W map to the folowing slims terms:"
14for term in slims:
15    print term, ontology[term].name
Note: See TracBrowser for help on using the repository browser.