plot_gsea: Plot GSEA normalized enrichment

View source: R/plot_gsea.R

plot_gseaR Documentation

Plot GSEA normalized enrichment

Description

Plot GSEA normalized enrichment

Usage

plot_gsea(
  gsea,
  fdr_cutoff = 0.2,
  fdr_colors = c(0.01, 0.05, 0.1, 0.2),
  show_overlap = TRUE,
  fdr.cutoff = NULL,
  fdr.colors = NULL,
  show.overlap = NULL
)

Arguments

gsea

Data frame output by SEARchways::BIGsea including pathway, FDR, and NES

fdr_cutoff

Numeric. Maximum FDR to plot. Default is 0.2

fdr_colors

Numeric vector. Cutoffs for color groups. Default is c(0.01, 0.05, 0.1, 0.2)

show_overlap

Logical if should show overlap across all facets even if some missing (TRUE) or give each facet it's own axis labels (FALSE). Default is TRUE

fdr.cutoff

Deprecated form of fdr_cutoff

fdr.colors

Deprecated form of fdr_colors

show.overlap

Deprecated form of show_overlap

Value

ggplot2 object

Examples

library(SEARchways)
library(dplyr)
#Get fold change information from example model
genes.FC <- example.model$lmerel %>%
            filter(variable %in% c("virus", "asthma")) %>%
            select(variable, gene, estimate)
#Run GSEA
example_gsea <- SEARchways::BIGsea(gene_df = genes.FC, category = "H", ID = "ENSEMBL")

#Plot
plot_gsea(example_gsea, fdr_cutoff = 0.5,
         fdr_colors = c(0.1, 0.5))

BIGslu/BIGpicture documentation built on Oct. 14, 2024, 9:30 p.m.