ribbonplot: Handle the positioning and labelling of a (spatstat) colour...

Description Usage Arguments Value Examples

View source: R/other.R

Description

Handle the positioning and labelling of a (spatstat) colour ramp more easily.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
ribbonplot(
  x,
  y,
  xprop,
  yprop,
  zlim,
  cm = NULL,
  steps = 4,
  sigdigits = NULL,
  rounding = NULL,
  vertical = TRUE,
  ...
)

Arguments

x

y-axis location of the colourramp lower-left corner.

xprop

proportion of plot width to be allocated to the colour ramp width

yprop

proportion of plot height to be allocated to the colour ramp height

zlim

minimum and maximum values for the colour ramp

cm

object of class 'colourmap' to plot (or default spatstat colour ramp if left null)

steps

how many numerical steps to label in the ramp legend

sigdigits

how to round the digits in the labels

rounding

to how many decimal places should the labels be rounded

vertical

whether the ramp is places as a vertical or horizontal ribbon

Value

an image ribbon added to an existing plot.

Examples

1
2
3
exampledensitymap <- density(cells, 0.05)
plot(exampledensitymap, ribbon=FALSE)
ribbonplot(x=0.1, y=0.1, xprop=0.03, yprop=0.2, zlim=c(min(exampledensitymap),max(exampledensitymap)), cex.axis=0.6, col.axis="white", col.ticks="white", las=2)

ahb108/sparch documentation built on Feb. 3, 2021, 1:21 a.m.