create_heatmap: Create heatmap

Description Usage Arguments Value Examples

View source: R/create_heatmap.R

Description

Creates a heatmap from a matrix, potentially with NA's

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
create_heatmap(
  mat = matrix(rnorm(100), nrow = 20),
  low = "#a4eaff",
  high = "#1C28A3",
  seg.color = "grey40",
  NA_color = "grey70",
  seg.shape = c("none", "cross", "line"),
  title = NULL,
  xtitle = NULL,
  ytitle = NULL,
  show.legend = TRUE,
  legend.title = "Expression"
)

Arguments

mat

A numeric matrix with features as rows

low

Color for lower gradient bound

high

Color for higher gradient bound

seg.color

Color of cell diagonal line for missing value tiles

NA_color

Color for missing value tiles

seg.shape

One of 'line', 'cross', or 'none'

title

Plot title

xtitle

X title

ytitle

Y title

show.legend

show.legend

legend.title

legend.title

Value

a ggplot object

Examples

1
2
3
4
create_heatmap(title = 'Example')
create_heatmap(low = 'green', high = 'purple')
create_heatmap(low = 'yellow', high = 'grey50')
create_heatmap(low = 'yellow', high = 'darkgreen')

aljabadi/Altools documentation built on Jan. 17, 2022, 8:55 a.m.