source: orange-bioinformatics/docs/reference-html/gsea2.py @ 1662:427f1876f3e6

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

Revamped documentation.

Line 
1import obiDicty
2import obiGeneSets
3import obiGsea
4import orange
5import obiGene
6
7dbc = obiDicty.DatabaseConnection()
8data = dbc.getData(sample='pkaC-', time="8")[0] #get first chip
9
10print "First 10 examples"
11for ex in data[:10]:
12    print ex
13
14matcher=obiGene.matcher([[obiGene.GMKEGG("ddi"),obiGene.GMDicty()]])
15
16genesets =  obiGeneSets.collections([":kegg:ddi"])
17res = obiGsea.runGSEA(data, matcher=matcher, minPart=0.05, geneSets=genesets, 
18    permutation="gene")
19
20print "GSEA results"
21print "%-40s %6s %6s %6s %7s" % ("LABEL", "NES", "P-VAL", "SIZE", "MATCHED") 
22for name,resu in res.items()[:10]: 
23    print "%-40s %6.3f %6.3f %6d %7d" % (name[:30], resu["nes"], resu["p"], 
24        resu["size"], resu["matched_size"]) 
25
Note: See TracBrowser for help on using the repository browser.