source: orange-bioinformatics/docs/modules/geneMatch1.py @ 1623:186d828e3699

Revision 1623:186d828e3699, 514 bytes checked in by mitar, 2 years ago (diff)

Renamed documentation directory.

Line 
1import obiGene
2import obiKEGG
3
4keggorg = obiKEGG.KEGGOrganism("mmu")
5kegg_genes = keggorg.get_genes() 
6
7query = [ "Fndc4", "Itgb8", "Cdc34", "Olfr1403" ] 
8
9gm = obiGene.GMKEGG("mmu") #use KEGG aliases for gene matching
10gm.set_targets(kegg_genes) #set KEGG gene aliases as targets
11
12pnames = keggorg.list_pathways()
13
14for name in query:
15    match = gm.umatch(name) # matched kegg alias or None
16    if match:
17        pwys = keggorg.get_pathways_by_genes([match])
18        print name, "is in", [ pnames[p] for p in pwys ] 
Note: See TracBrowser for help on using the repository browser.