padma 1.14.1
padma is a package that uses multiple factor analysis to calculate individualized pathway-centric scores of deviation with respect to the sampled population based on multi-omic assays (e.g., RNA-seq, copy number alterations, methylation, etc). In particular, padma characterizes individuals with aberrant multi-omic profiles for a given pathway of interest and quantifies this deviation with respect to the sampled population using a multi-omic consensus representation. Graphical and numerical outputs are provided to identify highly aberrant individuals for a particular pathway of interest, as well as the gene and omics drivers of aberrant multi-omic profiles.
The method implemented in this package is described in greater detail in the following pre-print:
Rau, A., Manansala, R., Flister, M. J., Rui, H., Jaffrézic, F., Laloë, D.*, and Auer, P. L.* (2019) Individualized multi-omic pathway deviation scores using multiple factor analysis bioRxiv, https://doi.org/10.1101/827022. *These authors contributed equally to this work.
Below, we provide a quick-start guide using a subset of the TCGA LUAD multi-omic data (included with the padma package) to illustrate the functionalities and output of the method.
As with any R package, after installation the padma package is loaded as follows:
library(padma)
Multi-omic data must be formatted as either a MultiAssayExperiment
object
(preferred) or as a named list of matrix
objects of matched
multi-omic data from a set of individuals, which is internally converted into
a MultiAssayExperiment
object. A small example dataset in list
format is provided in LUAD_subset
for multi-omic data (clinical, RNA-seq,
CNA, methylation, miRNA-seq) on 13 genes from the D4-GDI signaling pathway in
individuals with lung adenocarcinoma from TCGA. In practice, multi-omic
data do not need to be subsetted prior to running padma; this reduced
dataset is simply used as a minimal illustrative example.
A standard padma analysis for the D4-GDI signalling pathway takes as input
these pre-formatted MultiAssayExperiment
data (called below)
and the name of the desired pathway. Note that data should be
normalized, batch-corrected, and if appropriate, log-transformed prior
to using padma. Built-in pathway names and gene lists from the MSigDB
curated pathway set are provided in the msigdb
data provided with padma.
run_padma <-
padma(mae, pathway_name = "c2_cp_BIOCARTA_D4GDI_PATHWAY")
Individualized pathway deviation scores can then be accessed via the assay
accessor function, and per-gene contributions to these scores can be accessed
via the gene_deviation_scores()
accessor. In addition, a variety of plots can
be obtained, including
a factor map or partial factor map of individuals, and a plot of the
percentage contribution to each component by each considered omics.
assay(run_padma)
factorMap(run_padma)
factorMap(run_padma, partial_id = "TCGA-78-7536")
omicsContrib(run_padma)
Additional numerical outputs included in the run_padma
S4 object of class
padmaResults
include the per-gene pathway
deviation scores and full results from the MFA analysis. See the
following section for a more detailed description of these outputs.
A portion of the following text is taken from Rau et al. (2019).
Multiple factor analysis (MFA) represents an extension of principal component analysis for the case where multiple quantitative data tables are to be simultaneously analyzed. In particular, the MFA approach weights each table individually to ensure that tables with more features or those on a different scale do not dominate the analysis; all features within a given table are given the same weight. These weights are chosen such that the first eigenvalue of a PCA performed on each weighted table is equal to 1, ensuring that all tables play an equal role in the global multi-table analysis. According to the desired focus of the analysis, data can be structured either with molecular assays (e.g., RNA-seq, methylation, miRNA-seq, copy number alterations) as tables (and genes as features within omics), or with genes as tables (and molecular assays as features within genes). The MFA weights balance the contributions of each omic or of each gene, respectively. In padma, we focus on the latter strategy in order to allow different omics to contribute to a varying degree depending on the chosen pathway.
More precisely, consider a pathway or gene set composed of \(p\) genes (Figure 1A), each of which is measured using up to \(k\) molecular assays (e.g., RNA-seq, methylation, miRNA-seq, copy number alterations), contained in the set of gene-specific matrices \(X_1,\ldots, X_p\) that have the same \(n\) matched individuals (rows) and \(j_1,\ldots, j_p\) potentially unmatched variables (columns) in each, where \(j_g \in \lbrace 1, \ldots, k\rbrace\) for each gene \(g = 1,\ldots, p\). Because only the observations and not the variables are matched across data tables, genes may be represented by potentially different subset of omics data (e.g., only expression data for one gene, and expression and methylation data for another).
In the first step, these data tables are generally standardized (i.e., centered and scaled). Next, an individual PCA is performed using singular value decomposition for each gene table \(X_g\), and its largest singular value \(\lambda_g^1\) is calculated (Figure 1B). Then, all features in each gene table \(X_g\) are weighted by \(1/\lambda_g^1\), and a global PCA is performed using a singular value decomposition on the concatenated set of weighted standardized tables, \(X^\ast = \left[ \frac{X_1}{\lambda_1^1}, \ldots, \frac{X_p}{\lambda_p^1}\right]\) (Figure 1C). This yields a matrix of components (i.e., latent variables) in the observation and variable space.
The MFA thus provides a consensus across-gene representation of the individuals for a given pathway, and the global PCA performed on the weighted gene tables decomposes the consensus variance into orthogonal variables (i.e., principal components) that are ordered by the proportion of variance explained by each. The coordinates of each individual on these components, also referred to as factor scores, can be used to produce factor maps to represent individuals in this consensus space such that smaller distances reflect greater similarities among individuals. In addition, partial factor scores, which represent the position of individuals in the consensus for a given gene, can also be represented in the consensus factor map; the average of partial factor scores across all dimensions and genes for a given individual corresponds to the factor score (Figure 1D).
In the consensus space obtained from the MFA, the origin represents the ``average" pathway behavior across genes, omics, and individuals; individuals that are projected to increasingly distant points in the factor map represent those with increasingly aberrant values, with respect to this average, for one or more of the omics measures for one or more genes in the pathway. To quantify these aberrant individuals, we propose an individualized pathway deviation score \(d_i\) based on the multidimensional Euclidean distance of the MFA component loadings for each individual to the origin: \[\begin{equation*} d_i^2 = \sum_{\ell = 1}^L f_{i,\ell}^2, \end{equation*}\] where \(f_{i,\ell}\) corresponds to the MFA factor score of individual \(i\) in component \(\ell\), and \(L\) corresponds to the rank of \(X^\ast\). Note that this corresponds to the weighted Euclidean distance of the scaled multi-omic data (for the genes in a given pathway) of each individual to the origin. These individualized pathway deviation scores are thus nonnegative, where smaller values represent individuals for whom the average multi-omic pathway variation is close to the average, while larger scores represent individuals with increasingly aberrant multi-omic pathway variation with respect to the average. An individual with a large pathway deviation score is thus characterized by one or more genes, with one or more omic measures, that explain a large proportion of the global correlated information across the full pathway.
In order to quantify the role played by each gene for each individual, we decompose the individualized pathway deviation scores into gene-level contributions. Recall that the average of partial factor scores across all MFA dimensions corresponds to each individual’s factor score. We define the gene-level deviation for a given individual as follows: \[\begin{equation*} d_{i,g}=\frac{\sum_{\ell = 1}^L f_{i,\ell}\left(f_{i,\ell,g}-f_{i,\ell}\right)} {\sum_{\ell = 1}^L f_{i,\ell}^2}, \end{equation*}\] where as before \(f_{i,\ell}\) corresponds to the MFA factor score of individual \(i\) in component \(\ell\), \(L\) corresponds to the rank of \(X^\ast\), and \(f_{i,\ell,g}\) corresponds to the MFA partial factor score of individual \(i\) in gene \(g\) in component \(\ell\). Note that by construction, the contributions of all pathway genes to the overall deviation score sum to 0. In particular, per-gene contributions can take on both negative and positive values according to the extent to which the gene influences the deviation of the overall pathway score from the origin (i.e., the global center of gravity across individuals); large positive values correspond to tables with a large influence on the overall deviation of an individual, while large negative values correspond to genes that tend to be most similar to the global average.
LUAD_subset
: D4-GDI signaling pathway in the TCGA-LUAD multi-omic dataIn this vignette, we focus on the example of multi-omic (RNA-seq, methylation, copy number alterations, and miRNA-seq) data for the D4-GDI signaling pathway from individuals with lung adenocarcinoma (LUAD) from The Cancer Genome Atlas (TCGA) database. The multi-omic TCGA data were downloaded and processed as previously described, including batch correction for the plate effect. The total number of individuals considered here is \(n=144\). See Rau et al. (2019) for additional details about data processing and mapping of miRNAs to genes.
The D4-GDP dissociation inhibitor (GDI) signaling pathway is made up of 13 genes; it was chosen for follow-up here as it was identified as having individualized pathway deviation scores that are significantly positively correlated with smaller progression-free intervals. RNA-seq, methylation, and CNA measures are available for all 13 genes, with the exception of CYCS and PARP1, for which no methylation probes were measured the promoter region. In addition, miRNA-seq data were included for one predicted target pair: hsa-mir-421 \(\rightarrow\) CASP3.
The available multi-omic data for the D4-GDI signaling pathway in TCGA LUAD
patients is included within the padma package as the LUAD_subset
object,
which is a named list of data.frames
each containing the relevant data
(clinical parameters, RNA-seq, methylation, miRNA-seq, CNA) for the \(p=13\)
genes of the D4-GDI pathway in the \(n=144\) individuals.
names(LUAD_subset)
#> [1] "clinical" "rnaseq" "methyl" "mirna" "cna"
lapply(LUAD_subset, class)
#> $clinical
#> [1] "data.frame"
#>
#> $rnaseq
#> [1] "data.frame"
#>
#> $methyl
#> [1] "data.frame"
#>
#> $mirna
#> [1] "data.frame"
#>
#> $cna
#> [1] "data.frame"
lapply(LUAD_subset, dim)
#> $clinical
#> [1] 144 55
#>
#> $rnaseq
#> [1] 13 144
#>
#> $methyl
#> [1] 13 144
#>
#> $mirna
#> [1] 1 144
#>
#> $cna
#> [1] 13 144
There are some important data formatting issues that are worth mentioning here:
The clinical data (LUAD_subset$clinical
) have individuals as
rows and clinical variables as columns; all other datasets contain assay data
with biological entities (e.g., genes, miRNAs) as rows and
individuals as columns, with appropriate row and column names. Sample
(column) names for assay data correspond to the patient barcodes that are
provided in the bcr_patient_barcode
column of LUAD_subset$clinical
.
For LUAD_subset$mirna
, the first two
columns represent the miRNA ID (miRNA_lc
) and corresponding targeted gene
symbol (gene
).
A gene_map
data.frame can be optionally included to map biological entities
(e.g. miRNAs) to gene symbols as needed. By default, a set of 10,754
predicted miRNA gene targets with “Functional MTI” support type from
miRTarBase (version 7.0) are used for the gene_map
.
All omics data have already been appropriately pre-processed before subsetting to this pathway (e.g., RNA-seq and miRNA-seq data have been normalized and log-transformed, all datasets were batch-corrected for the plate effect).
Although padma does require that all datasets have the same number of individuals, and that all datasets are sorted so that individuals are in the same order, each dataset does not need to represent every considered gene. Note that in these data, a single gene (CASP3) is