pheat_display: Set display style for heatmap

Description Usage Arguments Value Examples

Description

Set display style for heatmap

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
pheat_display_main(
  ph,
  border_color = "grey60",
  fontsize = 10,
  title = NA,
  display_numbers = F
)

pheat_display_rows(
  ph,
  height = 10,
  show_names = TRUE,
  fontsize = NA,
  gaps = NULL,
  labels = NULL,
  dendrogram_width = NA
)

pheat_display_cols(
  ph,
  width = 10,
  show_names = TRUE,
  fontsize = NA,
  gaps = NULL,
  labels = NULL,
  dendrogram_height = NA
)

Arguments

ph

Heatmap of class "pheat"

border_color

Border color for cells. Set to NA to remove cell borders.

fontsize

Font size for row or column names

title

Title of heatmap

display_numbers

logical determining if the numeric values are also printed to the cells. If this is a matrix (with same dimensions as original matrix), the contents of the matrix are shown instead of original values.

height, width

Row height and column width. If set to NA, the size varies according to the available space

show_names

Show row or column names

gaps

Location of gaps between rows or columns. Gaps are located after the specified locations in the heatmap, moving from top to bottom for rows and left to right for columns. As a convenience, the user may provide a vector of row names after which gaps are to be placed.

labels

Custom labels to use in place of the row or column names in the data

dendrogram_width, dendrogram_height

Width and height of dendrograms for rows and columns, respectively, in points. If set to NA, the default value of 50 points will be used.

Value

A modified heatmap of class "pheat"

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
ph <- pheat(vendor_props)

# No border
pheat_display_main(ph, border_color = NA)

# Gaps between bacterial phyla
pheat_display_rows(ph, gaps = c(5, 10))

# Re-label samples
pheat_display_cols(ph, labels = paste("Sample", 1:30))

kylebittinger/pheatbuilder documentation built on Dec. 21, 2021, 8:45 a.m.