plotVisiumImg: Plot Visium sample on top of H&E

View source: R/visium.graphics.R View source: R/.ipynb_checkpoints/visium.utilities-checkpoint.R

plotVisiumImgR Documentation

Plot Visium sample on top of H&E

Description

Normally this function shouldn't be called directly. Use plotVisium instead

Usage

plotVisiumImg(
  xy,
  img,
  scale.factor,
  spot.radius,
  cex = 1,
  col = "red",
  border = NA,
  spot.dist = NULL,
  img.alpha = 1,
  xlim = NULL,
  ylim = NULL,
  symmetric.lims = TRUE,
  xlab = "",
  ylab = "",
  pie.fracs = NULL,
  pie.cols = NULL,
  pie.min.frac = 0.05,
  he.img.width = NULL,
  he.grayscale = FALSE,
  ...
)

Arguments

xy

seu@images[.]@coordinates

img

image (3D array)

scale.factor

see @images[.]@scale.factors$lowres

spot.radius

see @images[.]@spot.radius

cex

spot size

col

spot color

border

color of spot border

spot.dist

distance between spots (computed from xy by default)

img.alpha

alpha level for H&E image

xlim, ylim, xlab, ylab

parameters of plot function

symmetric.lims

logical, specifies whether image crop should be square

pie.fracs

if specified plots pies instead of simple cycles. Matrix with number of rows equal to the number of spots, and number of columns equal to pie pieces.

pie.cols

colors to be used for pie pieces (ncol(pie.fracs) should be equal to length(pie.cols))

pie.min.frac

all pieces with relative size less than pie.min.frac will be discared

he.img.width

integer, defines width (in pixels) the H&E figure should be resized to. No resizing if NULL (default)

he.grayscale

logical, specifies whether H&E image should be converted to grayscale

...

other parameters to be passed to plot function

Value

data.frame with user spot coordinates


iaaka/visutils documentation built on Jan. 17, 2025, 11:29 p.m.