calcGseaStat: Calculates GSEA statistics for a given query gene set

Description Usage Arguments Value Examples

View source: R/fgsea.R

Description

Takes O(k log k) time, where k is a size of 'selectedSize'.

Usage

1
2
3
4
5
6
7
8
calcGseaStat(
  stats,
  selectedStats,
  gseaParam = 1,
  returnAllExtremes = FALSE,
  returnLeadingEdge = FALSE,
  scoreType = c("std", "pos", "neg")
)

Arguments

stats

Named numeric vector with gene-level statistics sorted in decreasing order (order is not checked).

selectedStats

Indexes of selected genes in the 'stats' array.

gseaParam

GSEA weight parameter (0 is unweighted, suggested value is 1).

returnAllExtremes

If TRUE return not only the most extreme point, but all of them. Can be used for enrichment plot

returnLeadingEdge

If TRUE return also leading edge genes.

scoreType

This parameter defines the GSEA score type. Possible options are ("std", "pos", "neg")

Value

Value of GSEA statistic if both returnAllExtremes and returnLeadingEdge are FALSE. Otherwise returns list with the folowing elements:

Examples

1
2
3
4

Example output

Loading required package: Rcpp

fgsea documentation built on Nov. 8, 2020, 5:22 p.m.