<p>Hi everyone,</p>

<p>I have a microarray set of 26933 genes and 6 samples (3 controls and 3 mutants). I calculated differential expressed genes using limma&#39;s topTable() function. I got a result of this format:</p>

<pre>
&gt; head(res.new)</pre>

<pre>
             logFC   AveExpr         t      P.Value    adj.P.Val        B
17291881 -2.157936  9.021125 -41.49770 3.218440e-09 3.829474e-05 10.82552
17357688 -2.364349  7.160051 -41.15755 3.397181e-09 3.829474e-05 10.79753
17224251  1.820522 10.665778  37.01446 6.816679e-09 3.829474e-05 10.41426
17239845 -2.025497 10.054660 -35.87667 8.366167e-09 3.829474e-05 10.29350
17304523 -1.830077 10.117184 -35.36567 9.191590e-09 3.829474e-05 10.23680
17229782  2.716749  7.911040  35.24054 9.407763e-09 3.829474e-05 10.22267</pre>

<p>The logFC values are log2(FC). How do I convert the values <em>(positive and negative)</em> to normal fold changes?</p>

<p>I tried this:</p>

<p>#take 2^(absolute(log2FoldChange))</p>

<pre>
&gt; res.new$FC&lt;-2^(abs(res.new$logFC)) </pre>

<p>#change the sign of FC according to log2FC</p>

<pre>
&gt; res.new$FC&lt;-ifelse(res.new$logFC&lt;0,res.new$FC*(-1),res.new$FC*1) </pre>

<p>But I am not sure if I am correct. Please let me know.</p>

<p>Thanks!</p>

<p><code>res.new$FC &lt;- 2^res.new$logFC</code></p>

<p>Negative log2 fold-changes are just less than 1.</p>
