Plot_CellSR: Plot Cell density with SR values

Description Usage Arguments Details Value References Examples

View source: R/Plot_CellSR.R

Description

Density based visualization tool to generate figures that give the cell density distribution with SR value distribution

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
Plot_CellSR(
  Integration.l,
  coordinates = NULL,
  num_grid = 50,
  phi = 20,
  theta = 20,
  colpersp = NULL,
  colimage = NULL,
  colkeypersp = list(length = 0.2, width = 0.4, shift = 0.2, cex.axis = 0.6, cex.clab =
    0.7),
  colkeyimage = list(length = 0.2, width = 0.4, shift = -0.2, cex.axis = 0.6, cex.clab
    = 0.7),
  lighting = FALSE,
  lphi = 90,
  bty = "b",
  PDF = TRUE
)

Arguments

Integration.l

Typically, it is the output from InferLandmark function

coordinates

Optional. The previous reduced dimension coordinates, with rows lalabeling cells and two colums labeling reduced dimensions

num_grid

Number of grid points in each direction. Can be scalar or a length-2 integer vector

phi

The angles defining the viewing direction. phi gives the colatitude

theta

The angles defining the viewing direction. theta gives the azimuthal direction

colpersp

Color palette to be used for the colvar variable, i.e. the cell density. If colpersp is NULL (default) and colvar is specified, then a red-magenta-lightgray colorscheme will be used

colimage

Color palette to be used for the colvar variable, i.e. the SR values. If colimage is NULL (default) and colvar is specified, then a blue-lightblue-white colorscheme will be used.

colkeypersp

A logical, or a list (default) with parameters for the color key (legend). List parameters should be one of side, plot, length, width, dist, shift, addlines, col.clab, cex.clab, side.clab, line.clab, adj.clab, font.clab and the axis parameters at, labels, tick, line, pos, outer, font, lty, lwd, lwd.ticks, col.box, col.axis, col.ticks, hadj, padj, cex.axis, mgp, tck, tcl, las. The defaults for the parameters are length = 0.2, width = 0.4, shift = 0.15, cex.axis = 0.6, cex.clab = 0.65 The default is to draw the color key on side = 4, i.e. in the right margin. If colkeypersp = NULL then a color key will be added only if col is a vector. Setting colkeypersp = list(plot = FALSE) will create room for the color key without drawing it. if colkeypersp = FALSE, no color key legend will be added. See more details in ?plot3D::persp3D

colkeyimage

A logical, or a list (default) with parameters for the color key (legend). List parameters should be one of side, plot, length, width, dist, shift, addlines, col.clab, cex.clab, side.clab, line.clab, adj.clab, font.clab and the axis parameters at, labels, tick, line, pos, outer, font, lty, lwd, lwd.ticks, col.box, col.axis, col.ticks, hadj, padj, cex.axis, mgp, tck, tcl, las. The defaults for the parameters are length = 0.2, width = 0.4, shift = -0.15, cex.axis = 0.6, cex.clab = 0.65 The default is to draw the color key on side = 4, i.e. in the right margin. If colkeyimage = NULL then a color key will be added only if col is a vector. Setting colkeyimage = list(plot = FALSE) will create room for the color key without drawing it. if colkeyimage = FALSE, no color key legend will be added. See more details in ?plot3D::image3D

lighting

A logical. If TRUE, the facets will be illuminated, and colors may appear more bright. Default is FALSE

lphi

if finite values are specified for lphi, the surface is shaded as though it was being illuminated from the direction specified by colatitude lphi

bty

The type of the box ("b" or "f"), the default ("b") only drawing background panels

PDF

A logical. Output figure via pdf file or not, default is TRUE

Details

Density based visualization tool to generate figures that give the cell density distribution against SR value distribution

Value

A pdf file contains the generated figures

Integration.l If coordinates provided, it will be a list object integrates the input list and coordinates

References

Teschendorff AE, Tariq Enver. Single-cell entropy for accurate estimation of differentiation potency from a cell’s transcriptome. Nature communications 8 (2017): 15599. doi: 10.1038/ncomms15599.

Examples

1
2
3
4
5
6
7
data(tsne.o)
data(potS.v)
data(SR4.v)
potS.v <- 4 - potS.v
InferLandmark.o <- list(potencyState = potS.v, SR = SR4.v, coordinates = tsne.o)

CellSR.o <- Plot_CellSR(InferLandmark.o, PDF = FALSE)

ChenWeiyan/LandSCENT documentation built on Aug. 28, 2020, 9:55 p.m.