gmtHeat: Make a heatmap of gene expression grouped by gene sets

View source: R/gmt.R

gmtHeatR Documentation

Make a heatmap of gene expression grouped by gene sets

Description

Make a heatmap of gene expression grouped by gene sets

Usage

gmtHeat(
  counts,
  cond,
  gmt,
  con = NULL,
  labgenes = NULL,
  title = "",
  avgExp = TRUE,
  zscore = TRUE,
  colAnno = NULL,
  hmcol = NULL,
  intClus = TRUE,
  printEach = FALSE,
  retGroups = FALSE
)

Arguments

counts

data frame of normalized gene expression values

cond

character vector indicating which condition each column of counts belongs to

gmt

named list of gene sets to be used in the heatmap. Genes must be found in rownames(counts).

con

character indicating the control condition from cond. Or the order in which conditions in cond should appear on the heatmap.

labgenes

character indicating which genes (if any) should be labeled on the heatmap. Default NULL will label all genes. Set to "" to label no genes.

title

character indicating the title of the resulting heatmap

avgExp

Boolean indicating if gene expression should be averaged within each condition (TRUE) or if each individual replicate should be plotted (FALSE; default).

zscore

Boolean indicating if gene expression should be z-score scaled (TRUE; default) or not (FALSE).

colAnno

Dataframe with rownames=colnames counts and at least one column to annotate the columns of the heatmap. Leave NULL for no annotation.

hmcol

colorRampPalette object of length 100 indicating colour scheme of heatmap. Leave NULL for default colours.

intClus

Boolean indicating if hierarchical clustering should be performed within each gene set. Note trees will not be shown. Default = TRUE. If FALSE, heatmap will be presented in the order in which genes appear in the gene sets.

printEach

Boolean indicating if heatmaps for each individual gene set should be printed. Only works when intClus=TRUE. Trees will be shown. Default = FALSE.

retGroups

Boolean indicating if named list of data frames of gene expression subset to each gene set should be returned (z-score normalized if zscore=TRUE). Default is FALSE. if TRUE, heatmap won't be plotted.

Value

Annotated heatmap of gene expression of all gene sets provided or named list of data frames of gene expression subset to each gene set.


kevincjnixon/BinfTools documentation built on July 10, 2024, 11:46 a.m.