addBreakColorLegend: Adds a Legend to sp Plots with Colors and Breaks

Description Usage Arguments Value Author(s) See Also

View source: R/addBreakColorLegend.R

Description

Adds a Legend to sp Plots with Colors and Breaks

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
addBreakColorLegend(
  xleft,
  ybottom,
  xright,
  ytop,
  breaks,
  colors,
  printFormat = "4.2",
  ...
)

Arguments

xleft

a scalar of the left x position.

ybottom

a scalar of bottom y position.

xright

a scalar of the right x position.

ytop

a scalar of top y position.

colors

a vector of colors, should have one less element than the number of breaks.

brks

the breaks between color classes. Needs a lower bound, and upper bound, so there should be one more break than number of classes.

printFormat:

a character variable in '4.2' format where the 4 control the number of digits before the decimal, and 2 controls the number of digits after the decimal.

Value

add a color ramp legend as a rectangle to the currently active plot

Author(s)

Jay Ver Hoef

See Also

plotPointsRGB, rect,


jayverhoef/POP documentation built on June 29, 2021, 11:23 p.m.