plot-qntmap: Plot methods for 'qntmap' package

Description Usage Arguments See Also Examples

Description

S3 methods to plot object with original classes in qntmap package. See graphics::plot() for general use of plot. Mapping data (qm_xmap and qm_qntmap classes) are visualized by heat maps.

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
28
29
30
31
32
33
34
35
## S3 method for class 'qntmap'
plot(
  x,
  y = setdiff(names(x), c("x", "y"))[1L],
  zname = y,
  zlim = NULL,
  colors = c("magma", "viridis", "gray"),
  interactive = TRUE,
  unit = c("px", "um", "mm", "cm"),
  ...
)

## S3 method for class 'qm_xmap'
plot(
  x,
  y = setdiff(names(x), c("x", "y"))[1L],
  zname = y,
  zlim = NULL,
  colors = c("magma", "viridis", "gray"),
  interactive = TRUE,
  unit = c("px", "um", "mm", "cm"),
  ...
)

## S3 method for class 'qm_cluster'
plot(
  x,
  y = "cluster",
  zname = y,
  zlim = NULL,
  colors = c("magma", "viridis", "gray"),
  interactive = TRUE,
  unit = c("px", "um", "mm", "cm"),
  ...
)

Arguments

x

An object of class qntmap, qm_cluster, or qm_xmap, returned by quantify(), qntmap(), and read_xmap(), respectively.

zname, y

A string specifying a component of x to determine colors to fill the map. y is the alias of zname.

zlim

A range of z.

colors

A color scale "viridis" (default) or "gray" applicable when fill is continuous.

interactive

TRUE (default) produces plots with shiny WebUI, and FALSE produces plots with ggplot2::ggplot().

unit

Unit of x- and y-axis ("px", "um", "nm" or "cm").

...

Arguments passed to internal functions.

See Also

graphics::plot()

Examples

1
2
3
4
# qm_raster class object
d <- data.frame(expand.grid(x = 1:5, y = 1:5), fill = runif(5))
class(d) <- c("qm_raster", class(d))
plot(d, "fill", interactive = FALSE)

atusy/qntmap documentation built on Dec. 3, 2019, 12:11 p.m.