Comparing groups with makeContrast in edgeR
1
0
Entering edit mode
2.1 years ago
sea.joson ▴ 10

Hello!

I recently used edgeR for differential analysis and I just had something I couldn't figure out. Background: I have 23 samples (treated with H2O2 and not treated; 0h, 3h, 6hr, 9hr). Unequal number of replicates. So essentially, my groups looked like this:

> group
 [1] None.0hr None.0hr None.0hr None.0hr None.3hr None.3hr None.3hr None.3hr None.6hr None.6hr None.6hr None.6hr
[13] None.9hr H2O2.3hr H2O2.3hr H2O2.3hr H2O2.3hr H2O2.6hr H2O2.6hr H2O2.6hr H2O2.6hr H2O2.9hr H2O2.9hr

So when it came to doing makeContrast, I had to decide which ones I wanted to compare, right? So I first chose to compare none.3hr with none.0hr, none.6hr with none.0hr, and none.9hr with none.0hr. This was just to make sure that there were no differential expressions going on throughout those time points.

Next, I did pairwise comparisons of treated vs not treated at the same time points. So: H2O2.3hr with none.3hr, H202.6hr with none.6r, and H2O2.9hr, with none. 9hr. I also then compared those treated samples with none.0hr.

Ultimately, my question is, does this seem valid? My doubt comes from the edgeR user guide. In section 3.3.1, it shows this:

> my.contrasts <- makeContrasts(
+ Drug.1vs0 = Drug.1h-Drug.0h,
+ Drug.2vs0 = Drug.2h-Drug.0h,
+ Placebo.1vs0 = Placebo.1h-Placebo.0h,
+ Placebo.2vs0 = Placebo.2h-Placebo.0h,
+ DrugvsPlacebo.0h = Drug.0h-Placebo.0h,
+ DrugvsPlacebo.1h = (Drug.1h-Drug.0h)-(Placebo.1h-Placebo.0h),
+ DrugvsPlacebo.2h = (Drug.2h-Drug.0h)-(Placebo.2h-Placebo.0h),
+ levels=design)

Why was comparing the drug vs placebo at 1 hour computed like that? Why is it (Drug.1h-Drug.0h)-(Placebo.1h-Placebo.0h) and not simply Drug.1h-Placebo.1h?

edgeR • 757 views
ADD COMMENT
1
Entering edit mode
2.1 years ago

Why is it (Drug.1h-Drug.0h)-(Placebo.1h-Placebo.0h) and not simply Drug.1h-Placebo.1h?

With Drug.1h-Placebo.1h you estimate the difference between drug and placebo at time point 1h. Let's say you find this difference to be close to 0 (for a certain gene, gene A).

With (Drug.1h-Drug.0h)-(Placebo.1h-Placebo.0h) you ask whether a gene responds differently to drug as time goes on. That is, you want to estimate the interaction effect between drug and time. Say the difference between drug and placebo at 0h is large for gene A. Then, yes, there is a sizeable interaction because as time goes on the difference between drug and placebo has shrunk from being large to being ~0. If you just tested for Drug.1h-Placebo.1h you would have missed this. In other words, you ask whether the slope of the regression of expression vs time in "drug" group is different from the slope of that regression in "placebo" group. (It's easier to see with a plot).

A suboptimal alternative would be to test Drug.0h-Placebo.0h and then ask for genes that are differential in Drug.0h-Placebo.0h but not in Drug.1h-Placebo.1h or vice-versa or differential in both but in opposite directions. This is a poor strategy in part because you rely on some cutoffs to decide significance and in part because you don't account for variability across time points.

ADD COMMENT

Login before adding your answer.

Traffic: 2119 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6