# [BioC] ANOVA analysis using edgeR

Ryan C. Thompson rct at thompsonclan.org
Wed Aug 6 01:00:29 CEST 2014

```Hello,

It looks like you have already figured out how to perform an ANOVA-like
test for differences among your five groups using edgeR. I believe your
confusion is coming from the fact that the ANOVA-like test is only
testing 4 contrasts, while you want to test 9 of them. The test only
uses 4 contrasts because a test for differences among 5 groups has 4
degrees of freedom. The other five contrasts that you desire are
actually just linear combinations of the first 4. Let's use the example
you gave in your email, using group A as the intercept, so the 4
comparisons represented in the design are B-A, C-A, D-A, and E-A. If you
wanted to calculate the C-B comparison, note that ((C-A) - (B-A)) = C -
A - B + A = C - B. So, to get the logFC for C-B, you simply take the C-A
logFC and subtract the B-A logFC. In a similar fashion, every other
comparison can be computed in terms of the original 4 comparisons.

Note that while only 4 comparisons are explicitly represented in the
model, the ANOVA-like test is in fact testing for any evidence of
differences between any of the 5 groups, which includes all 9
comparisons that you have specified, as well as the tenth comparison,
E-D, which you didn't specify (there are 10 possible pairwise
comparisons between 5 samples).

-Ryan

On 07/31/2014 03:52 PM, Yogender Gowtham wrote:
> Hello All:
>
> I am Yogender Gowtham, a graduate student from Clemson University. We are
> using RNA-Seq to investigate the transcriptional changes of Chinese Hamster
> Ovary (CHO) cells during serum-free adaptation. Our experiment has two cell
> lines, say Y and Z,  under 3 different serum concentrations, say, 10%, 5%
> and 0%. Cell line Z could not be adapted to 0% serum condition and hence we
> have unbalanced set of conditions. For clarity, the conditions are listed
> below
>
> A - Y at 0%                 D - Z at 5%
> B - Y at 5%                 E - Z at 10%
> C - Y at 10%
>
> We have come up with 9 different pairwise comparisons based on the
> scientific questions we want to answer. But performing so many pairwise
> comparisons will lead to more liberal FDR values. Hence we want to perform
> ANOVA analysis on all the five conditions.
>
> Based on section 3.2.6 which explains how to perform ANOVA-like analysis.
> >From what I understand, it contrasts each column with intercept and will
> list any differences that are non-zero (B-A, C-A, D-A, E-A). But ideally we
> want B-A, B-C, B-D, E-B, C-A, D-C, E-C, D-A, or E-A comparisons in an ANOVA
> test.
>
> If anyone can suggest a method on edgeR to perform ANOVA tests, that will
> be perfect. If not, can someone suggest other possible packages that could
> help me do an ANOVA analysis on multiple groups.
>
> Regards
>
>
> Yogender Kumar Gowtham
> Clemson University
> Department of Bioengineering
> 202 Biosystems Research Complex
> Clemson, SC
> (864)650-7451
>
> 	[[alternative HTML version deleted]]
>
> _______________________________________________
> Bioconductor mailing list
> Bioconductor at r-project.org
> https://stat.ethz.ch/mailman/listinfo/bioconductor
> Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor

```