pathwaySummary: Pathway Summary Statistics

View source: R/utils.R

pathwaySummaryR Documentation

Pathway Summary Statistics

Description

Generates a table of pathway activity profiles per sample

Usage

pathwaySummary(
  exprsMat,
  pathwayRef,
  id = "ENSEMBL",
  zNormalize = FALSE,
  method = FALSE,
  deGenes = NULL,
  trim = 0,
  tScores = NULL
)

Arguments

exprsMat

Gene expression matrix with row names as genes and samples as columns.

pathwayRef

Table of pathway-gene associations. Created from pathwayGeneTab function.

id

Gene annotation type in the row name of gene expression data.

zNormalize

Normalization of pathway summary score.

method

Choice of how to summarize gene ranks into pathway statistics.

deGenes

List of differentially expressed genes along with t-scores. Only necessary if working on Top 50% summary method.

trim

Percentage of top and bottom ranked genes to be excluded from pathway summary statistics.

tScores

Argument for-top-50-percent-genes method.

Value

pathExp Table of pathway activity profiles per sample.

Examples

pathTab <- tibble::tribble(
 ~Pathway, ~ENTREZID,  ~ENSEMBL,
 "Path1",   "125",      "ENSG00000196616",
 "Path1",   "3099",     "ENSG00000159399",
 "Path2",   "5230",     "ENSG00000102144",
 "Path2",   "5162",     "ENSG00000168291"
 )
exprsMat <- matrix(2 * (seq_len(12)), 4, 3)
rownames(exprsMat) <- pathTab$ENSEMBL
colnames(exprsMat) <- LETTERS[seq_len(3)]
pathwaySummary(exprsMat, pathTab, method = "x2")

pouryany/PanomiR documentation built on Aug. 20, 2022, 11:17 p.m.