Skip to content

Commit

Permalink
update doc
Browse files Browse the repository at this point in the history
  • Loading branch information
nargesr committed Feb 9, 2024
1 parent d18c7b3 commit e6a0a66
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 18 deletions.
Binary file modified docs/doctrees/api.doctree
Binary file not shown.
Binary file modified docs/doctrees/environment.pickle
Binary file not shown.
7 changes: 5 additions & 2 deletions docs/html/_modules/PyWGCNA/wgcna.html
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@ <h1>Source code for PyWGCNA.wgcna</h1><div class="highlight"><pre>
<span class="kn">from</span> <span class="nn">gseapy.plot</span> <span class="kn">import</span> <span class="n">dotplot</span>
<span class="kn">from</span> <span class="nn">pyvis.network</span> <span class="kn">import</span> <span class="n">Network</span>
<span class="kn">from</span> <span class="nn">reactome2py</span> <span class="kn">import</span> <span class="n">analysis</span>
<span class="kn">from</span> <span class="nn">pandas.api.types</span> <span class="kn">import</span> <span class="n">is_numeric_dtype</span>

<span class="kn">from</span> <span class="nn">PyWGCNA.geneExp</span> <span class="kn">import</span> <span class="o">*</span>

Expand Down Expand Up @@ -172,7 +173,6 @@ <h1>Source code for PyWGCNA.wgcna</h1><div class="highlight"><pre>
<span class="n">BOLD</span> <span class="o">=</span> <span class="s2">&quot;</span><span class="se">\033</span><span class="s2">[1m&quot;</span>
<span class="n">UNDERLINE</span> <span class="o">=</span> <span class="s2">&quot;</span><span class="se">\033</span><span class="s2">[4m&quot;</span>


<div class="viewcode-block" id="WGCNA"><a class="viewcode-back" href="../../api.html#PyWGCNA.wgcna.WGCNA">[docs]</a><span class="k">class</span> <span class="nc">WGCNA</span><span class="p">(</span><span class="n">GeneExp</span><span class="p">):</span>
<span class="sd">&quot;&quot;&quot;</span>
<span class="sd"> A class used to do weighted gene co-expression network analysis.</span>
Expand Down Expand Up @@ -2467,7 +2467,7 @@ <h1>Source code for PyWGCNA.wgcna</h1><div class="highlight"><pre>
<span class="sd"> :param MEs: Module eigengenes in a multi-set format.</span>
<span class="sd"> :type MEs: dict</span>
<span class="sd"> :param greyLast: Normally the color grey is reserved for unassigned genes; hence the grey module is not a proper module and it is conventional to put it last. If this is not desired, set the parameter to FALSE. (default = True)</span>
<span class="sd"> :type greyLast:bool</span>
<span class="sd"> :type greyLast: bool</span>
<span class="sd"> :param greyName: Name of the grey module eigengene. (default = &quot;MEgrey&quot;)</span>
<span class="sd"> :type greyName: str</span>
<span class="sd"> :param orderBy: Specifies the set by which the eigengenes are to be ordered (in all other sets as well). Defaults to the first set in useSets (or the first set, if useSets is not given). (defualt = 0)</span>
Expand Down Expand Up @@ -2842,6 +2842,9 @@ <h1>Source code for PyWGCNA.wgcna</h1><div class="highlight"><pre>
<span class="n">data</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">datExpr</span><span class="o">.</span><span class="n">obs</span><span class="o">.</span><span class="n">copy</span><span class="p">()[</span><span class="n">metaData</span><span class="p">]</span>
<span class="n">datTraits</span> <span class="o">=</span> <span class="n">pd</span><span class="o">.</span><span class="n">DataFrame</span><span class="p">(</span><span class="n">index</span><span class="o">=</span><span class="n">data</span><span class="o">.</span><span class="n">index</span><span class="p">)</span>
<span class="k">for</span> <span class="n">i</span> <span class="ow">in</span> <span class="nb">range</span><span class="p">(</span><span class="n">data</span><span class="o">.</span><span class="n">shape</span><span class="p">[</span><span class="mi">1</span><span class="p">]):</span>
<span class="k">if</span> <span class="n">is_numeric_dtype</span><span class="p">(</span><span class="n">data</span><span class="o">.</span><span class="n">iloc</span><span class="p">[:,</span> <span class="n">i</span><span class="p">]</span><span class="o">.</span><span class="n">dtypes</span><span class="p">):</span>
<span class="n">datTraits</span><span class="p">[</span><span class="n">data</span><span class="o">.</span><span class="n">columns</span><span class="p">[</span><span class="n">i</span><span class="p">]]</span> <span class="o">=</span> <span class="n">data</span><span class="o">.</span><span class="n">iloc</span><span class="p">[:,</span> <span class="n">i</span><span class="p">]</span>
<span class="k">continue</span>
<span class="n">data</span><span class="o">.</span><span class="n">iloc</span><span class="p">[:,</span> <span class="n">i</span><span class="p">]</span> <span class="o">=</span> <span class="n">data</span><span class="o">.</span><span class="n">iloc</span><span class="p">[:,</span> <span class="n">i</span><span class="p">]</span><span class="o">.</span><span class="n">astype</span><span class="p">(</span><span class="nb">str</span><span class="p">)</span>
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">np</span><span class="o">.</span><span class="n">unique</span><span class="p">(</span><span class="n">data</span><span class="o">.</span><span class="n">iloc</span><span class="p">[:,</span> <span class="n">i</span><span class="p">]))</span> <span class="o">==</span> <span class="mi">2</span><span class="p">:</span>
<span class="n">datTraits</span><span class="p">[</span><span class="n">data</span><span class="o">.</span><span class="n">columns</span><span class="p">[</span><span class="n">i</span><span class="p">]]</span> <span class="o">=</span> <span class="n">data</span><span class="o">.</span><span class="n">iloc</span><span class="p">[:,</span> <span class="n">i</span><span class="p">]</span>
Expand Down
25 changes: 9 additions & 16 deletions docs/html/api.html
Original file line number Diff line number Diff line change
Expand Up @@ -929,25 +929,18 @@
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>MEs</strong> (<em>dict</em>) – Module eigengenes in a multi-set format.</p></li>
<li><p><strong>greyLast</strong> – Normally the color grey is reserved for unassigned genes; hence the grey module is not a proper module and it is conventional to put it last. If this is not desired, set the parameter to FALSE. (default = True)</p></li>
<li><p><strong>greyLast</strong> (<em>bool</em>) – Normally the color grey is reserved for unassigned genes; hence the grey module is not a proper module and it is conventional to put it last. If this is not desired, set the parameter to FALSE. (default = True)</p></li>
<li><p><strong>greyName</strong> (<em>str</em>) – Name of the grey module eigengene. (default = “MEgrey”)</p></li>
<li><p><strong>orderBy</strong> (<em>int</em>) – Specifies the set by which the eigengenes are to be ordered (in all other sets as well). Defaults to the first set in useSets (or the first set, if useSets is not given). (defualt = 0)</p></li>
<li><p><strong>order</strong> (<em>list</em>) – Allows the user to specify a custom ordering.</p></li>
<li><p><strong>useSets</strong> (<em>list</em>) – Allows the user to specify for which sets the eigengene ordering is to be performed.</p></li>
</ul>
</dd>
</dl>
<p>:type greyLast:bool
:param greyName: Name of the grey module eigengene. (default = “MEgrey”)
:type greyName: str
:param orderBy: Specifies the set by which the eigengenes are to be ordered (in all other sets as well). Defaults to the first set in useSets (or the first set, if useSets is not given). (defualt = 0)
:type orderBy: int
:param order: Allows the user to specify a custom ordering.
:type order: list
:param useSets: Allows the user to specify for which sets the eigengene ordering is to be performed.
:type useSets: list</p>
<dl class="field-list simple">
<dt class="field-odd">Returns</dt>
<dd class="field-odd"><p>A dictionary of the same type as MEs containing the re-ordered eigengenes.</p>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>A dictionary of the same type as MEs containing the re-ordered eigengenes.</p>
</dd>
<dt class="field-even">Return type</dt>
<dd class="field-even"><p>dict</p>
<dt class="field-odd">Return type</dt>
<dd class="field-odd"><p>dict</p>
</dd>
</dl>
</dd></dl>
Expand Down

0 comments on commit e6a0a66

Please sign in to comment.