source: orange-bioinformatics/docs/reference/obiGeneSets.htm @ 1661:6c5f448f2563

Revision 1661:6c5f448f2563, 3.9 KB checked in by mitar, 2 years ago (diff)

Moved style CSS file.

Line 
1<html>
2
3<head>
4<title>obiGeneSets</title>
5<link rel=stylesheet href="style.css" type="text/css">
6<link rel=stylesheet href="style-print.css" type="text/css" media=print>
7</head>
8
9<body>
10<h1>obiGeneSets</h1>
11<index name="modules/gene sets">
12
13<p><code>obiGeneSets</code> is a module for gene set management. It can also load gene set collections in <code>gmt</code> format used by Molecular Signatures Database (MSigDB).</p>
14
15<dl class="attributes">
16
17<dt>list_all()</dt>
18<dd>
19Lists gene sets available in the local and <code>orngServerFiles</code> repositories. It returns a list of tuples of (hierarchy, organism, available_locally).
20</dd>
21
22<dt>collections(col1, col2, ....)</dt>
23<dd>
24Loads and combines gene sets from various sources: <code>gmt</code>, GO, KEGG and others. Returns a <code>GeneSets</code> object. All arguments are gene set specifications. They can be either:
25<ul>
26<li>filename of a <code>gmt</code> file,</li>
27<li>tuple <code>(hierarchy, organism)</code> (for example <code>(("KEGG",), "10090")</code>), or</li>
28<li>instance of <code>GeneSets</code></li>
29</ul>
30<h3>Usage one-liners</h3>
31<p>Gene sets from KEGG and GO for mouse.</p>
32<xmp class=code>obiGeneSets.collections((("KEGG",), "10090"), (("GO",), "10090"))
33</xmp>
34<p>Open gene sets from &quot;specific.gmt&quot; from the current working directory.</p>
35<xmp class=code>obiGeneSets.collections("specific.gmt")
36</xmp>
37<p>We can also combine above examples.</p>
38<xmp class=code>obiGeneSets.collections((("KEGG",), "10090"), (("GO",), "10090"), "specific.gmt")
39</xmp>
40</dd>
41
42<dt>register(geneSets, serverFiles=None)</dt>
43<dd>
44Registers given geneSets (<code>GeneSets</code> object) locally if <code>serverFiles</code> is None or to <code>orngServerFiles</code> repository if authenticated connection is passed. The gene set is registred by the common organism (or None if organisms are different) and the most common hierarchy.
45</dd>
46
47</dl>
48
49<h2>GeneSet: a single set of genes</h2>
50
51<code>GeneSet</code> objects contain a single gene set.
52
53<dl class="attributes">
54<dt>GeneSet(genes=None, name=None, id=None, description=None, link=None, organism=None, hierarchy=None, pair=None)</dt>
55<dd>Creates a GeneSet instance. If a tuple (name, genes) is passed as the <code>pair</code> argument, then the tuple is converted to the new represetation. Kept for backward compatibility.</dd>
56</dl>
57
58<p class="section">Object properties and funtions</p>
59
60<dl class="attributes">
61<dt>organism</dt>
62<dd>Taxid.</dd>
63<dt>hierarchy</dt>
64<dd>Hierarchy should be formated as a tuple, for example <code>("GO", "biological_process")</code>.</dd>
65<dt>genes</dt>
66<dd>A set of genes. Genes are strings.</dd>
67<dt>id</dt>
68<dt>name</dt>
69<dt>description</dt>
70<dt>link</dt>
71<dt>cname(source=True, name=True)</dt>
72<dd>Constructs a gene set name with the hierarchy.</dd>
73<dt>to_odict(self, source=True, name=True)y</dt>
74<dd>Returns a pair (id, listofgenes), like in the old format.</dd>
75</dl>
76
77<h2>GeneSets: a colletions of gene sets</h2>
78
79<code>GeneSets</code> objects contain multiple gene sets of type <code>GeneSet</code>. It is a subclass of Python's <code>set</code> type.
80
81<dl class="attributes">
82<dt>GeneSets(input=None)</dt>
83<dd>Creates a GeneSets instance. If it is an iterable, the <code>GeneSets</code> object is initialized with gene sets from input. If input is a dictionary, the gene sets are converted to the current format.</dd>
84</dl>
85
86<p class="section">Object properties and funtions</p>
87
88<dl class="attributes">
89<dt>set_hierarchy(hierarchy)</dt>
90<dd>Sets hierarchy for all gene sets.</dd>
91<dt>common_org()</dt>
92<dd>Returns the common organism (or None if there is no common organism).</dd>
93<dt>hierarchies()</dt>
94<dd>Returns a set of all hierachies.</dd>
95<dt>common_hierarchy</dt>
96<dd>Returns a common hierarchy.</dd>
97<dt>split_by_hierarchy()</dt>
98<dd>Splits gene sets by hierarchies. Returns a list of <code>GeneSets</code> object.</dd>
99<dt>to_odict()</dt>
100<dd>Return gene sets in old dictionary format.<dd>
101</dl>
102
103</body>
104</html>
105
Note: See TracBrowser for help on using the repository browser.