Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Gene-set tests

A gene-set test asks a question of a pathway or a signature as a whole, for one contrast of the linear model fitted to every gene. Two questions differ Goeman & Bühlmann, 2007:

A self-contained test finds a set significant when its genes respond, however many other genes respond too: in a response that touches thousands of genes, many sets are. A competitive test asks whether a set stands out from the other genes, and so suits ranking many sets, such as a pathway collection. Every test here works on the linear model, so it allows any design and contrast and does not permute samples; all but romer take voom’s precision weights.

The effects of each gene

All five tests start from the same decomposition Wu et al., 2010, section 4.1. The design is reparametrized so that the contrast is its last coefficient, and the QR decomposition of that design turns each gene’s data into a contrast effect u0u_0 and dd residual effects u1,…,udu_1, \dots, u_d, independent with variance σ2\sigma^2 under the model. The contrast effect over the residual standard deviation is the gene’s t-statistic.

camera

Genes are correlated, so a set’s genes are not independent evidence. camera turns each gene’s moderated t-statistic into a z-score and compares the mean z-score of the set’s mm genes with that of the other genes by a two-sample t-test, with the variance of the set’s mean inflated by

VIF=1+(m−1)ρ,\mathrm{VIF} = 1 + (m - 1)\rho,

for an inter-gene correlation ρ\rho Wu & Smyth, 2012. The default ρ=0.01\rho = 0.01 is limma’s; inter_gene_correlation=None estimates it for each set from its residual effects. use_ranks=True gives the rank version, a correlation-adjusted Wilcoxon-Mann-Whitney test.

fry

fry averages each gene’s standardized effects over the set into a vector bb of d+1d + 1 values. Under the null hypothesis a random rotation of the residual space leaves the data’s distribution unchanged, so

T=b0∑k=1dbk2/dT = \frac{b_0}{\sqrt{\sum_{k=1}^{d} b_k^2 / d}}

follows a t distribution on dd degrees of freedom: the p-value that roast with the mean statistic would give with infinitely many rotations Giner & Smyth, 2016. fry is fast enough for thousands of sets and gives a directional and a mixed p-value for each.

roast and mroast

roast draws random rotations of the residual space and compares a set statistic with its values under them Wu et al., 2010Langsrud, 2005. The statistic summarizes the genes’ z-scores: their mean (the default), which detects sets in which most genes change in the same direction, or a floored mean, the mean of the top half or the mean square, which detect sets in which fewer genes change, the mean square the fewest. With bb of BB rotations at least as extreme as the observed statistic, the p-value is

p=b+1B+1p = \frac{b + 1}{B + 1}

Phipson & Smyth, 2010, so it is never zero; each rotation also gives its mirror image for the up and down alternatives. roast reports the proportion of the set’s genes that are active in each direction. mroast tests many sets with the same rotations and adjusts their p-values. Rotations come from a seeded numpy generator, so a seed gives the same p-values every time; they agree with limma’s within Monte Carlo error.

romer

romer ranks every gene’s moderated t-statistic among all genes and compares a set’s mean rank with its values when every gene’s rotated statistics are ranked again Majewski et al., 2010. Like gene set enrichment analysis Subramanian et al., 2005 it pits the sets against each other, but by rotating the residual space instead of permuting samples, so it works for any contrast with residual degrees of freedom. Before rotating, each gene’s contrast effect is shrunk by its posterior probability of being differentially expressed, so that strongly responding genes do not inflate the rotated statistics.

Choices

References
  1. Goeman, J. J., & Bühlmann, P. (2007). Analyzing gene expression data in terms of gene sets: methodological issues. Bioinformatics, 23(8), 980–987. 10.1093/bioinformatics/btm051
  2. Wu, D., Lim, E., Vaillant, F., Asselin-Labat, M.-L., Visvader, J. E., & Smyth, G. K. (2010). ROAST: rotation gene set tests for complex microarray experiments. Bioinformatics, 26(17), 2176–2182. 10.1093/bioinformatics/btq401
  3. Wu, D., & Smyth, G. K. (2012). Camera: a competitive gene set test accounting for inter-gene correlation. Nucleic Acids Research, 40(17), e133. 10.1093/nar/gks461
  4. Giner, G., & Smyth, G. K. (2016). FRY: a fast approximation to ROAST gene set test with mean aggregated set statistics. F1000Research 5, 2605 (slides). 10.7490/f1000research.1113351.1
  5. Langsrud, �yvind. (2005). Rotation tests. Statistics and Computing, 15(1), 53–60. 10.1007/s11222-005-4789-5
  6. Phipson, B., & Smyth, G. K. (2010). Permutation p-values should never be zero: calculating exact p-values when permutations are randomly drawn. Statistical Applications in Genetics and Molecular Biology, 9(1), Article 39. 10.2202/1544-6115.1585
  7. Majewski, I. J., Ritchie, M. E., Phipson, B., Corbin, J., Pakusch, M., Ebert, A., Busslinger, M., Koseki, H., Hu, Y., Smyth, G. K., Alexander, W. S., Hilton, D. J., & Blewitt, M. E. (2010). Opposing roles of polycomb repressive complexes in hematopoietic stem and progenitor cells. Blood, 116(5), 731–739. 10.1182/blood-2009-12-260760
  8. Subramanian, A., Tamayo, P., Mootha, V. K., Mukherjee, S., Ebert, B. L., Gillette, M. A., Paulovich, A., Pomeroy, S. L., Golub, T. R., Lander, E. S., & Mesirov, J. P. (2005). Gene set enrichment analysis: A knowledge-based approach for interpreting genome-wide expression profiles. Proceedings of the National Academy of Sciences, 102(43), 15545–15550. 10.1073/pnas.0506580102