<!DOCTYPE html>
<!-- Generated by pkgdown: do not edit by hand --><html lang="en"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"><title>Plot the Phylostratum or Divergence Stratum Enrichment of a given Gene Set — PlotEnrichment • myTAI</title><!-- favicons --><link rel="icon" type="image/png" sizes="16x16" href="../favicon-16x16.png"><link rel="icon" type="image/png" sizes="32x32" href="../favicon-32x32.png"><link rel="apple-touch-icon" type="image/png" sizes="180x180" href="../apple-touch-icon.png"><link rel="apple-touch-icon" type="image/png" sizes="120x120" href="../apple-touch-icon-120x120.png"><link rel="apple-touch-icon" type="image/png" sizes="76x76" href="../apple-touch-icon-76x76.png"><link rel="apple-touch-icon" type="image/png" sizes="60x60" href="../apple-touch-icon-60x60.png"><script src="../deps/jquery-3.6.0/jquery-3.6.0.min.js"></script><meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"><link href="../deps/bootstrap-5.3.1/bootstrap.min.css" rel="stylesheet"><script src="../deps/bootstrap-5.3.1/bootstrap.bundle.min.js"></script><link href="../deps/font-awesome-6.4.2/css/all.min.css" rel="stylesheet"><link href="../deps/font-awesome-6.4.2/css/v4-shims.min.css" rel="stylesheet"><script src="../deps/headroom-0.11.0/headroom.min.js"></script><script src="../deps/headroom-0.11.0/jQuery.headroom.min.js"></script><script src="../deps/bootstrap-toc-1.0.1/bootstrap-toc.min.js"></script><script src="../deps/clipboard.js-2.0.11/clipboard.min.js"></script><script src="../deps/search-1.0.0/autocomplete.jquery.min.js"></script><script src="../deps/search-1.0.0/fuse.min.js"></script><script src="../deps/search-1.0.0/mark.min.js"></script><!-- pkgdown --><script src="../pkgdown.js"></script><meta property="og:title" content="Plot the Phylostratum or Divergence Stratum Enrichment of a given Gene Set — PlotEnrichment"><meta name="description" content="This function computes and visualizes the significance of enriched (over or underrepresented) Phylostrata or Divergence Strata within an input test.set."><meta property="og:description" content="This function computes and visualizes the significance of enriched (over or underrepresented) Phylostrata or Divergence Strata within an input test.set."><meta property="og:image" content="https://drostlab.github.io/myTAI/logo.png"></head><body>
    <a href="#main" class="visually-hidden-focusable">Skip to contents</a>


    <nav class="navbar navbar-expand-lg fixed-top bg-light" data-bs-theme="light" aria-label="Site navigation"><div class="container">

    <a class="navbar-brand me-2" href="../index.html">myTAI</a>

    <small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.0.0</small>


    <button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
      <span class="navbar-toggler-icon"></span>
    </button>

    <div id="navbar" class="collapse navbar-collapse ms-3">
      <ul class="navbar-nav me-auto"><li class="active nav-item"><a class="nav-link" href="../reference/index.html">Reference</a></li>
<li class="nav-item dropdown">
  <button class="nav-link dropdown-toggle" type="button" id="dropdown-articles" data-bs-toggle="dropdown" aria-expanded="false" aria-haspopup="true">Articles</button>
  <ul class="dropdown-menu" aria-labelledby="dropdown-articles"><li><a class="dropdown-item" href="../articles/Advanced.html">Advanced Phylotranscriptomics Analyses</a></li>
    <li><a class="dropdown-item" href="../articles/Enrichment.html">Enrichment Analyses</a></li>
    <li><a class="dropdown-item" href="../articles/Expression.html">Gene Expression Analysis with `myTAI`</a></li>
    <li><a class="dropdown-item" href="../articles/Intermediate.html">Intermediate Phylotranscriptomics Analyses</a></li>
    <li><a class="dropdown-item" href="../articles/Introduction.html">Introduction to the myTAI package</a></li>
    <li><a class="dropdown-item" href="../articles/Phylostratigraphy.html">Discussing Genomic Phylostratigraphy</a></li>
  </ul></li>
<li class="nav-item"><a class="nav-link" href="../news/index.html">Changelog</a></li>
      </ul><ul class="navbar-nav"><li class="nav-item"><form class="form-inline" role="search">
 <input class="form-control" type="search" name="search-input" id="search-input" autocomplete="off" aria-label="Search site" placeholder="Search for" data-search-index="../search.json"></form></li>
<li class="nav-item"><a class="external-link nav-link" href="https://github.com/drostlab/myTAI/" aria-label="GitHub"><span class="fa fab fa-github fa-lg"></span></a></li>
      </ul></div>


  </div>
</nav><div class="container template-reference-topic">
<div class="row">
  <main id="main" class="col-md-9"><div class="page-header">
      <img src="../logo.png" class="logo" alt=""><h1>Plot the Phylostratum or Divergence Stratum Enrichment of a given Gene Set</h1>
      <small class="dont-index">Source: <a href="https://github.com/drostlab/myTAI/blob/HEAD/R/PlotEnrichment.R" class="external-link"><code>R/PlotEnrichment.R</code></a></small>
      <div class="d-none name"><code>PlotEnrichment.Rd</code></div>
    </div>

    <div class="ref-description section level2">
    <p>This function computes and visualizes the significance of enriched (over or underrepresented) Phylostrata or Divergence Strata within an input <code>test.set</code>.</p>
    </div>

    <div class="section level2">
    <h2 id="ref-usage">Usage<a class="anchor" aria-label="anchor" href="#ref-usage"></a></h2>
    <div class="sourceCode"><pre class="sourceCode r"><code><span><span class="fu">PlotEnrichment</span><span class="op">(</span></span>
<span>  <span class="va">ExpressionSet</span>,</span>
<span>  <span class="va">test.set</span>,</span>
<span>  use.only.map <span class="op">=</span> <span class="cn">FALSE</span>,</span>
<span>  measure <span class="op">=</span> <span class="st">"log-foldchange"</span>,</span>
<span>  complete.bg <span class="op">=</span> <span class="cn">TRUE</span>,</span>
<span>  legendName <span class="op">=</span> <span class="st">""</span>,</span>
<span>  over.col <span class="op">=</span> <span class="st">"steelblue"</span>,</span>
<span>  under.col <span class="op">=</span> <span class="st">"midnightblue"</span>,</span>
<span>  epsilon <span class="op">=</span> <span class="fl">1e-05</span>,</span>
<span>  cex.legend <span class="op">=</span> <span class="fl">1</span>,</span>
<span>  cex.asterisk <span class="op">=</span> <span class="fl">1</span>,</span>
<span>  plot.bars <span class="op">=</span> <span class="cn">TRUE</span>,</span>
<span>  p.adjust.method <span class="op">=</span> <span class="cn">NULL</span>,</span>
<span>  <span class="va">...</span></span>
<span><span class="op">)</span></span></code></pre></div>
    </div>

    <div class="section level2">
    <h2 id="arguments">Arguments<a class="anchor" aria-label="anchor" href="#arguments"></a></h2>


<dl><dt id="arg-expressionset">ExpressionSet<a class="anchor" aria-label="anchor" href="#arg-expressionset"></a></dt>
<dd><p>a standard PhyloExpressionSet or DivergenceExpressionSet object (in case <code>only.map = FALSE</code>).</p></dd>


<dt id="arg-test-set">test.set<a class="anchor" aria-label="anchor" href="#arg-test-set"></a></dt>
<dd><p>a character vector storing the gene ids for which PS/DS enrichment analyses should be performed.</p></dd>


<dt id="arg-use-only-map">use.only.map<a class="anchor" aria-label="anchor" href="#arg-use-only-map"></a></dt>
<dd><p>a logical value indicating whether instead of a standard <code>ExpressionSet</code> only a <code>Phylostratigraphic Map</code> or <code>Divergene Map</code> is passed to this function.</p></dd>


<dt id="arg-measure">measure<a class="anchor" aria-label="anchor" href="#arg-measure"></a></dt>
<dd><p>a character string specifying the measure that should be used to quantify over and under representation of PS/DS. Measures can either be <code>measure = "foldchange"</code> (odds) or <code>measure = "log-foldchange"</code> (log-odds).</p></dd>


<dt id="arg-complete-bg">complete.bg<a class="anchor" aria-label="anchor" href="#arg-complete-bg"></a></dt>
<dd><p>a logical value indicating whether the entire background set
of the input <code>ExpressionSet</code> should be considered when performing Fisher's exact
test (<code>complete.bg = TRUE</code>) or whether genes that are stored in <code>test.set</code>
should be excluded from the background set before performing Fisher's exact test
(<code>complete.bg = FALSE</code>).</p></dd>


<dt id="arg-legendname">legendName<a class="anchor" aria-label="anchor" href="#arg-legendname"></a></dt>
<dd><p>a character string specifying whether "PS" or "DS" are used to compute relative expression profiles.</p></dd>


<dt id="arg-over-col">over.col<a class="anchor" aria-label="anchor" href="#arg-over-col"></a></dt>
<dd><p>color of the overrepresentation bars.</p></dd>


<dt id="arg-under-col">under.col<a class="anchor" aria-label="anchor" href="#arg-under-col"></a></dt>
<dd><p>color of the underrepresentation bars.</p></dd>


<dt id="arg-epsilon">epsilon<a class="anchor" aria-label="anchor" href="#arg-epsilon"></a></dt>
<dd><p>a small value to shift values by epsilon to avoid log(0) computations.</p></dd>


<dt id="arg-cex-legend">cex.legend<a class="anchor" aria-label="anchor" href="#arg-cex-legend"></a></dt>
<dd><p>the <code>cex</code> value for the legend.</p></dd>


<dt id="arg-cex-asterisk">cex.asterisk<a class="anchor" aria-label="anchor" href="#arg-cex-asterisk"></a></dt>
<dd><p>the <code>cex</code> value for the asterisk.</p></dd>


<dt id="arg-plot-bars">plot.bars<a class="anchor" aria-label="anchor" href="#arg-plot-bars"></a></dt>
<dd><p>a logical value specifying whether or not bars should be visualized or whether only <code>p.values</code> and <code>enrichment.matrix</code> should be returned.</p></dd>


<dt id="arg-p-adjust-method">p.adjust.method<a class="anchor" aria-label="anchor" href="#arg-p-adjust-method"></a></dt>
<dd><p>correction method to adjust p-values for multiple comparisons (see <code><a href="https://rdrr.io/r/stats/p.adjust.html" class="external-link">p.adjust</a></code> for possible methods). E.g., <code>p.adjust.method = "BH"</code> (Benjamini &amp; Hochberg (1995)) or <code>p.adjust.method = "bonferroni"</code> (Bonferroni correction).</p></dd>


<dt id="arg--">...<a class="anchor" aria-label="anchor" href="#arg--"></a></dt>
<dd><p>default graphics parameters.</p></dd>

</dl></div>
    <div class="section level2">
    <h2 id="details">Details<a class="anchor" aria-label="anchor" href="#details"></a></h2>
    <p>This <em>Phylostratum</em> or <em>Divergence Stratum</em> enrichment analysis is motivated
by Sestak and Domazet-Loso (2015) who perform <em>Phylostratum</em> or <em>Divergence Stratum</em> enrichment analyses to correlate organ evolution with the origin of organ specific genes.</p>
<p>In detail this function takes the <em>Phylostratum</em> or <em>Divergence Stratum</em> distribution of all genes stored in the input <code>ExpressionSet</code> as background set and
the <em>Phylostratum</em> or <em>Divergence Stratum</em> distribution of the <code>test.set</code> and performes a <code><a href="https://rdrr.io/r/stats/fisher.test.html" class="external-link">fisher.test</a></code> for each <em>Phylostratum</em> or <em>Divergence Stratum</em> to quantify the statistical significance of over- or underrepresentated <em>Phylostrata</em> or <em>Divergence Strata</em> within the set of selected <code>test.set</code> genes.</p>
<p>To visualize the odds or log-odds of over or underrepresented genes within the <code>test.set</code> the following procedure is performed:</p>
<ul><li><p>N_ij denotes the number of genes in group j and deriving from PS i, with <em>i = 1, .. , n</em> and where <em>j = 1</em> denotes the background set and <em>j = 2</em> denotes the <code>test.set</code></p></li>
<li><p>N_i. denotes the total number of genes within PS i</p></li>
<li><p>N_.j denotes the total number of genes within group j</p></li>
<li><p>N_.. is the total number of genes within all groups j and all PS i</p></li>
<li><p>f_ij = N_ij / N_.. and g_ij = f_ij / f_.j denote relative frequencies between groups</p></li>
<li><p>f_i. denotes the between group sum of f_ij</p></li>
</ul><p>The result is the fold-change value (odds) denoted as C = g_i2 / f_i. which is visualized above and below zero.</p>
<p>In case a large number of Phylostrata or Divergence Strata is included in the input
 <code>ExpressionSet</code>, p-values returned by <code>PlotEnrichment</code> should be adjusted for
 multiple comparisons which can be done by specifying the <code>p.adjust.method</code> argument.</p>
    </div>
    <div class="section level2">
    <h2 id="references">References<a class="anchor" aria-label="anchor" href="#references"></a></h2>
    <p>Sestak and Domazet-Loso (2015). Phylostratigraphic Profiles in Zebrafish Uncover Chordate Origins of the Vertebrate Brain. Mol. Biol. Evol. 32(2): 299-312.</p>
    </div>
    <div class="section level2">
    <h2 id="see-also">See also<a class="anchor" aria-label="anchor" href="#see-also"></a></h2>
    <div class="dont-index"><p><code><a href="EnrichmentTest.html">EnrichmentTest</a></code>, <code><a href="https://rdrr.io/r/stats/fisher.test.html" class="external-link">fisher.test</a></code></p></div>
    </div>
    <div class="section level2">
    <h2 id="author">Author<a class="anchor" aria-label="anchor" href="#author"></a></h2>
    <p>Hajk-Georg Drost</p>
    </div>

    <div class="section level2">
    <h2 id="ref-examples">Examples<a class="anchor" aria-label="anchor" href="#ref-examples"></a></h2>
    <div class="sourceCode"><pre class="sourceCode r"><code><span class="r-in"><span></span></span>
<span class="r-in"><span><span class="fu"><a href="https://rdrr.io/r/utils/data.html" class="external-link">data</a></span><span class="op">(</span><span class="va">PhyloExpressionSetExample</span><span class="op">)</span></span></span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="fu"><a href="https://rdrr.io/r/base/Random.html" class="external-link">set.seed</a></span><span class="op">(</span><span class="fl">123</span><span class="op">)</span></span></span>
<span class="r-in"><span><span class="va">test_set</span> <span class="op">&lt;-</span> <span class="fu"><a href="https://rdrr.io/r/base/sample.html" class="external-link">sample</a></span><span class="op">(</span><span class="va">PhyloExpressionSetExample</span><span class="op">[</span> , <span class="fl">2</span><span class="op">]</span>,<span class="fl">10000</span><span class="op">)</span></span></span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co">## Examples with complete.bg = TRUE</span></span></span>
<span class="r-in"><span><span class="co">## Hence: the entire background set of the input ExpressionSet is considered </span></span></span>
<span class="r-in"><span><span class="co">## when performing Fisher's exact test </span></span></span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># measure: log-foldchange</span></span></span>
<span class="r-in"><span><span class="fu">PlotEnrichment</span><span class="op">(</span>ExpressionSet <span class="op">=</span> <span class="va">PhyloExpressionSetExample</span>,</span></span>
<span class="r-in"><span>               test.set      <span class="op">=</span> <span class="va">test_set</span> , </span></span>
<span class="r-in"><span>               legendName    <span class="op">=</span> <span class="st">"PS"</span>, </span></span>
<span class="r-in"><span>               measure       <span class="op">=</span> <span class="st">"log-foldchange"</span><span class="op">)</span></span></span>
<span class="r-plt img"><img src="PlotEnrichment-1.png" alt="" width="700" height="433"></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $p.values</span>
<span class="r-out co"><span class="r-pr">#&gt;</span>       PS1       PS2       PS3       PS4       PS5       PS6       PS7       PS8 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 0.4693540 0.2894449 0.9407912 0.7844042 0.6941342 0.3376881 0.7599214 0.3534216 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span>       PS9      PS10      PS11      PS12 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 0.2070409 0.5247578 0.8226034 0.4035404 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $enrichment.matrix</span>
<span class="r-out co"><span class="r-pr">#&gt;</span>            BG_Set     Test_Set</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS1  -0.007173974  0.010879188</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS2   0.013314604 -0.020557911</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS3   0.004816575 -0.007381227</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS4  -0.006219847  0.009440103</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS5   0.016601366 -0.025707696</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS6  -0.027725930  0.041308721</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS7   0.022156857 -0.034481130</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS8  -0.068477640  0.098607672</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS9  -0.081220293  0.115747944</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS10  0.024420954 -0.038081789</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS11 -0.020107047  0.030153208</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS12  0.022430353 -0.034915301</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-in"><span>               </span></span>
<span class="r-in"><span>               </span></span>
<span class="r-in"><span><span class="co"># measure: foldchange</span></span></span>
<span class="r-in"><span><span class="fu">PlotEnrichment</span><span class="op">(</span>ExpressionSet <span class="op">=</span> <span class="va">PhyloExpressionSetExample</span>,</span></span>
<span class="r-in"><span>               test.set      <span class="op">=</span> <span class="va">test_set</span> , </span></span>
<span class="r-in"><span>               legendName    <span class="op">=</span> <span class="st">"PS"</span>, </span></span>
<span class="r-in"><span>               measure       <span class="op">=</span> <span class="st">"foldchange"</span><span class="op">)</span></span></span>
<span class="r-plt img"><img src="PlotEnrichment-2.png" alt="" width="700" height="433"></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $p.values</span>
<span class="r-out co"><span class="r-pr">#&gt;</span>       PS1       PS2       PS3       PS4       PS5       PS6       PS7       PS8 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 0.4693540 0.2894449 0.9407912 0.7844042 0.6941342 0.3376881 0.7599214 0.3534216 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span>       PS9      PS10      PS11      PS12 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 0.2070409 0.5247578 0.8226034 0.4035404 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $enrichment.matrix</span>
<span class="r-out co"><span class="r-pr">#&gt;</span>         BG_Set  Test_Set</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS1  0.9950396  1.007570</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS2  1.0092721 -1.014352</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS3  1.0033453 -1.005131</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS4  0.9956976  1.006565</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS5  1.0115771 -1.017984</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS6  0.9809623  1.029052</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS7  1.0154904 -1.024211</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS8  0.9536013  1.070804</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS9  0.9452185  1.083597</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS10 1.0170758 -1.026755</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS11 0.9861409  1.021149</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS12 1.0156713 -1.024500</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-in"><span>   </span></span>
<span class="r-in"><span>               </span></span>
<span class="r-in"><span><span class="co">## Examples with complete.bg = FALSE</span></span></span>
<span class="r-in"><span><span class="co">## Hence: the test.set genes are excluded from the background set before</span></span></span>
<span class="r-in"><span><span class="co">## Fisher's exact test is performed</span></span></span>
<span class="r-in"><span>     </span></span>
<span class="r-in"><span>                                       </span></span>
<span class="r-in"><span><span class="co"># measure: log-foldchange</span></span></span>
<span class="r-in"><span><span class="fu">PlotEnrichment</span><span class="op">(</span>ExpressionSet <span class="op">=</span> <span class="va">PhyloExpressionSetExample</span>,</span></span>
<span class="r-in"><span>               test.set      <span class="op">=</span> <span class="va">test_set</span> ,</span></span>
<span class="r-in"><span>                complete.bg  <span class="op">=</span> <span class="cn">FALSE</span>,</span></span>
<span class="r-in"><span>               legendName    <span class="op">=</span> <span class="st">"PS"</span>, </span></span>
<span class="r-in"><span>               measure       <span class="op">=</span> <span class="st">"log-foldchange"</span><span class="op">)</span></span></span>
<span class="r-plt img"><img src="PlotEnrichment-3.png" alt="" width="700" height="433"></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $p.values</span>
<span class="r-out co"><span class="r-pr">#&gt;</span>       PS1       PS2       PS3       PS4       PS5       PS6       PS7       PS8 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 0.6315000 0.4817838 0.9727738 0.8469003 0.7924055 0.5264504 0.8657001 0.5361027 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span>       PS9      PS10      PS11      PS12 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 0.3975804 0.6883696 0.8910157 0.5916625 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $enrichment.matrix</span>
<span class="r-out co"><span class="r-pr">#&gt;</span>            BG_Set     Test_Set</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS1  -0.003093762  0.007785426</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS2   0.005800680 -0.014757232</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS3   0.002089538 -0.005291689</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS4  -0.002683565  0.006756538</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS5   0.007244479 -0.018463217</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS6  -0.011836114  0.029472607</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS7   0.009695676 -0.024785453</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS8  -0.028657241  0.069950431</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS9  -0.033781176  0.081966769</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS10  0.010698553 -0.027383236</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS11 -0.008615890  0.021537317</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS12  0.009816700 -0.025098601</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-in"><span>               </span></span>
<span class="r-in"><span>               </span></span>
<span class="r-in"><span><span class="co"># measure: foldchange</span></span></span>
<span class="r-in"><span><span class="fu">PlotEnrichment</span><span class="op">(</span>ExpressionSet <span class="op">=</span> <span class="va">PhyloExpressionSetExample</span>,</span></span>
<span class="r-in"><span>               test.set      <span class="op">=</span> <span class="va">test_set</span> , </span></span>
<span class="r-in"><span>               complete.bg   <span class="op">=</span> <span class="cn">FALSE</span>,</span></span>
<span class="r-in"><span>               legendName    <span class="op">=</span> <span class="st">"PS"</span>, </span></span>
<span class="r-in"><span>               measure       <span class="op">=</span> <span class="st">"foldchange"</span><span class="op">)</span>     </span></span>
<span class="r-plt img"><img src="PlotEnrichment-4.png" alt="" width="700" height="433"></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $p.values</span>
<span class="r-out co"><span class="r-pr">#&gt;</span>       PS1       PS2       PS3       PS4       PS5       PS6       PS7       PS8 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 0.6315000 0.4817838 0.9727738 0.8469003 0.7924055 0.5264504 0.8657001 0.5361027 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span>       PS9      PS10      PS11      PS12 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 0.3975804 0.6883696 0.8910157 0.5916625 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $enrichment.matrix</span>
<span class="r-out co"><span class="r-pr">#&gt;</span>         BG_Set  Test_Set</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS1  0.9978578  1.005411</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS2  1.0040290 -1.010282</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS3  1.0014499 -1.003676</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS4  0.9981414  1.004695</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS5  1.0050356 -1.012884</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS6  0.9918281  1.020642</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS7  1.0067492 -1.017344</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS8  0.9803147  1.049725</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS9  0.9768405  1.058501</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS10 1.0074452 -1.019167</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS11 0.9940378  1.015061</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> PS12 1.0068286 -1.017552</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-in"><span>               </span></span>
</code></pre></div>
    </div>
  </main><aside class="col-md-3"><nav id="toc" aria-label="Table of contents"><h2>On this page</h2>
    </nav></aside></div>


    <footer><div class="pkgdown-footer-left">
  <p>Developed by Hajk-Georg Drost, Jaruwatana Sodai Lotharukpong, Nikola Kalábová, Kristian K Ullrich.</p>
</div>

<div class="pkgdown-footer-right">
  <p>Site built with <a href="https://pkgdown.r-lib.org/" class="external-link">pkgdown</a> 2.1.0.</p>
</div>

    </footer></div>





  </body></html>

