add_pathways: Pathway Alterations

View source: R/add-pathways.R

add_pathwaysR Documentation

Pathway Alterations

Description

Please note that only ⁠sample_id column⁠, and columns with .Amp, .Del, .fus or no suffix are accepted. Any gene column with no suffix will be assumed to be a mutation.

Usage

add_pathways(
  gene_binary,
  pathways = c(names(gnomeR::pathways)),
  custom_pathways = NULL,
  other_vars = NULL,
  count_pathways_by = deprecated()
)

Arguments

gene_binary

a binary matrix from create_gene_binary()

pathways

a vector of pre-coded pathways to annotate. The options are names(gnomeR::pathways) ("RTK/RAS", "Nrf2", "PI3K", "TGFB", "p53", "Wnt", "Myc", "Cell cycle", "Hippo", "Notch"). You can pass multiple pathway names, or NULL. By default, all pathways defined in gnomeR::pathways will be included. Included default pathways are alteration-specific, meaning a specific type of alteration (mut/cna/fusion) is required to mark a 1 for that pathway.

custom_pathways

a vector of alterations to annotate as a single pathway, or a list of custom pathways (see gnomeR::pathways as example). You must specify the alteration type for each gene using .mut, .Amp, .Del suffix, e.g. c("TP53.mut", "CDKN2A.Amp"). If you wish to count any type of alteration on that gene towards the pathway you can use the .any suffix (e.g. c("TP53.any")).

other_vars

One or more column names (quoted or unquoted) in data to be retained in resulting data frame. Default is NULL.

count_pathways_by

deprecated

Details

Input a binary matrix of patients x alterations and return a dataframe with a column per pathway indicating if default or custom oncogenic signaling pathways are activated in each sample. Default package pathways were sourced from Sanchez-Vega, F et al., 2018.

Please check for gene aliases in your data set before using.

Value

a data frame: each sample is a row, columns are pathways, with values of 0/1 depending on pathway alteration status.

Source

Sanchez-Vega, F., Mina, M., Armenia, J., Chatila, W. K., Luna, A., La, K. C., Dimitriadoy, S., Liu, D. L., Kantheti, H. S., Saghafinia, S., Chakravarty, D., Daian, F., Gao, Q., Bailey, M. H., Liang, W. W., Foltz, S. M., Shmulevich, I., Ding, L., Heins, Z., Ochoa, A., … Schultz, N. (2018). Oncogenic Signaling Pathways in The Cancer Genome Atlas. Cell, 173(2), 321–337.e10. https://doi.org/10.1016/j.cell.2018.03.035

Examples


gene_binary <- create_gene_binary(mutation = gnomeR::mutations,
 cna = gnomeR::cna,
 fusion = gnomeR::sv)
pathway_df <- add_pathways(gene_binary, pathways = "Notch")


MSKCC-Epi-Bio/gnomeR documentation built on March 28, 2024, 2:42 a.m.