Twenty thousand tests,and six samples
Genomic data is wide and shallow. Almost every statistical method in the field exists to survive that shape.
Tens of thousands of genes against a handful of replicates. Classical statistics assumes the opposite.
Discrete, non-negative, and with variance that grows with the mean. Normal-theory tests do not fit.
Batch, sex, ancestry, run date. All of it correlates with something, and none of it is what you asked about.
At p < 0.05,a thousand genes lie
Run twenty thousand tests on pure noise and a thousand come back significant. The first thing to correct for, and the easiest to botch.
Bonferroni controls the chance of any false positive at all, which is the right goal for a handful of confirmatory tests and far too strict for a screen. Benjamini-Hochberg controls the proportion of your hits that are false, which is what you actually want when the output is a candidate list. Report the adjusted value, and say which method produced it.
Why RNA-seqneeds its own tests
Read counts are discrete, non-negative, and more variable than a Poisson allows. A t-test on them is the wrong tool.
Poisson plus an over-dispersion term, which is what real biological replicates actually look like.
Estimates are borrowed across genes, which is the trick that makes three replicates usable.
DESeq2 and edgeR normalise internally. Feeding them TPM or FPKM invalidates the model.
DESeq2 and edgeR both model counts as negative binomial and both borrow information across genes to estimate dispersion, which is what makes three replicates workable at all. Give them raw counts. They normalise internally, and handing them TPM or FPKM breaks the assumption the whole model rests on.
Batch effectsoutrank your biology
The largest source of variation in a genomics dataset is frequently the day it was processed, and no test will tell you that.
Plot the first two principal components before testing anything. If samples cluster by processing date or sequencing run rather than by condition, that is your dominant signal. It can be modelled — include batch as a covariate — but only if the design allows it. A batch perfectly confounded with your condition cannot be rescued by statistics, only by a better experiment.
RStudio Server isalready built
Nothing here needs compiling. Pick a machine, and these two commands put it on there.
$ dxflow workflow create --identity rstudio hub://rstudio
$ dxflow workflow start rstudio