19 Global association
The first step in multi-omic integration is exploratory: do the tables associate at all? Global association methods compare the overall variation in one table to that in another, without looking at individual features.
This chapter gives examples of three common approaches: the Mantel test, Procrustes analysis, and MiRKAT.
19.1 Data
As an example, we use the HintikkaXOData dataset (Section D.5) from Hintikka et al. (2021), in which rats were fed a high-fat or a low-fat diet, with or without prebiotics. The data is a MultiAssayExperiment (Ramos et al. 2017) (see Chapter 3) with three experiments from the same samples: microbial abundances, metabolite concentrations and biomarkers.
# Available experiments
experiments(mae)
## ExperimentList class object of length 3:
## [1] microbiota: TreeSummarizedExperiment with 12706 rows and 40 columns
## [2] metabolites: TreeSummarizedExperiment with 38 rows and 40 columns
## [3] biomarkers: TreeSummarizedExperiment with 39 rows and 40 columnsBefore the analysis, we preprocess both tables. The microbiome data is agglomerated to genus level and transformed to relative abundances. For the metabolites, we drop features with missing values, apply a log10 transformation, and standardize each metabolite.
# Microbiome
mae[["microbiota"]] <- agglomerateByRank(mae[["microbiota"]], rank = "Genus")
mae[["microbiota"]] <- transformAssay(
mae[["microbiota"]],
method = "relabundance"
)
# Metabolites
tse <- mae[["metabolites"]]
tse <- tse[rowSums(is.na(assay(tse, "nmr"))) == 0, ]
tse <- transformAssay(tse, assay.type = "nmr", method = "log10")
tse <- transformAssay(
tse,
assay.type = "log10", method = "standardize", MARGIN = "rows"
)
mae[["metabolites"]] <- tseAll three methods operate on sample-by-sample distances, so we calculate a dissimilarity matrix for each table: Bray-Curtis (Bray and Curtis 1957) for the microbiome and Euclidean for the metabolites. The samples are in the same order in both tables.
dist_mb <- getDissimilarity(
mae[["microbiota"]],
assay.type = "relabundance",
method = "bray"
)
dist_mt <- getDissimilarity(
mae[["metabolites"]],
assay.type = "standardize",
method = "euclidean"
)19.2 Mantel test
The Mantel test (Mantel 1967) correlates two distance matrices. We use the implementations of the Mantel test and PROTEST in the vegan package (Oksanen et al. 2020). If samples that are similar in microbiome composition are also similar in metabolite profiles, the correlation is positive. Significance is assessed with permutations.
library(vegan)
set.seed(123)
res_mantel <- mantel(
dist_mb, dist_mt,
method = "spearman", permutations = 999
)
res_mantel
##
## Mantel statistic based on Spearman's rank correlation rho
##
## Call:
## mantel(xdis = dist_mb, ydis = dist_mt, method = "spearman", permutations = 999)
##
## Mantel statistic r: 0.181
## Significance: 0.006
##
## Upper quantiles of permutations (null model):
## 90% 95% 97.5% 99%
## 0.0906 0.1104 0.1332 0.1630
## Permutation: free
## Number of permutations: 999The Mantel statistic r = 0.18 (p = 0.006) shows a weak but significant positive association between the microbiome and the metabolite profiles.
19.3 Procrustes analysis
Procrustes analysis rotates, scales, and reflects one ordination to match another as closely as possible. The permutation-based PROTEST (Peres-Neto and Jackson 2001) then tests whether the two ordinations agree more than expected by chance. Here, we compare the first two axes of principal coordinate analysis (PCoA) (GOWER 1966) of each table.
pcoa_mb <- cmdscale(dist_mb, k = 2)
pcoa_mt <- cmdscale(dist_mt, k = 2)
set.seed(123)
res <- protest(pcoa_mb, pcoa_mt, permutations = 999)
res
##
## Call:
## protest(X = pcoa_mb, Y = pcoa_mt, permutations = 999)
##
## Procrustes Sum of Squares (m12 squared): 0.788
## Correlation in a symmetric Procrustes rotation: 0.46
## Significance: 0.001
##
## Permutation: free
## Number of permutations: 999The correlation in the symmetric Procrustes rotation is 0.46 (p = 0.001), so the two ordinations agree more than expected by chance.
The result can be visualized by plotting how much each sample shifts between the two ordinations (Figure 19.1).
19.4 Kernel test (MiRKAT)
MiRKAT is a kernel-based framework for testing associations between microbiome profiles and outcomes (Zhao et al. 2015). Its kernel RV (KRV) test (Zhan et al. 2017) assesses the association between the microbiome and a multivariate outcome, such as a metabolite table.
The KRV test also indicates a significant association between the microbiome and the metabolite table (p <0.001).
The original MiRKAT test takes a single outcome. By running it separately for each metabolite, we can see which metabolites are associated with the overall microbiome composition. Because we perform multiple tests, the p-values are adjusted for multiple testing (Benjamini and Hochberg 1995).
pvals <- apply(mat_mt, 2, function(y) {
MiRKAT(y = y, Ks = kernel_mb, out_type = "C", method = "davies")[["p_values"]]
})
padj <- p.adjust(pvals, method = "fdr")
res <- data.frame(p = pvals, p_adj = padj)
res <- res[order(res[["p_adj"]]), ]
head(res, 10)
## p p_adj
## Butyrate 0.000e+00 0.000e+00
## Glucose 0.000e+00 0.000e+00
## Nicotinate 3.292e-08 3.292e-07
## 1,3-dihydroxyacetone 3.752e-05 2.814e-04
## Uracil 1.385e-04 8.308e-04
## Propionate 1.107e-03 5.535e-03
## Glycerol 1.820e-03 7.801e-03
## Acetate 6.689e-03 2.041e-02
## Threonine 6.805e-03 2.041e-02
## Pyruvate 5.954e-03 2.041e-02The next chapters investigate the associations between the omic layers in more detail.