colorBar: Plot color bar

Description Usage Arguments Value

View source: R/pkColorbar.r

Description

Plot color bar

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
36
37
38
39
40
41
42
43
colorBar(
  breaks = seq(0, 1, 0.1),
  colors = gray.colors(length(breaks) - 1),
  barlength = 0.5,
  barlwd = 0.5,
  axislab = "Colorscale",
  axislabline = 2.25,
  locut = F,
  hicut = F,
  slantwidth = 0.05,
  smallticks = F,
  axisbreaks = breaks,
  axisbreaklab = axisbreaks,
  tck1 = -0.015,
  tck2 = -0.03,
  axiscex = 0.8,
  labelcex = 1,
  pmgp = c(2.5, 0.66, 0),
  pmar = c(3, 0.5, 0.5, 0.5),
  ...
)

pkColorbar(
  breaks = seq(0, 1, 0.1),
  colors = gray.colors(length(breaks) - 1),
  barlength = 0.5,
  barlwd = 0.5,
  axislab = "Colorscale",
  axislabline = 2.25,
  locut = F,
  hicut = F,
  slantwidth = 0.05,
  smallticks = F,
  axisbreaks = breaks,
  axisbreaklab = axisbreaks,
  tck1 = -0.015,
  tck2 = -0.03,
  axiscex = 0.8,
  labelcex = 1,
  pmgp = c(2.5, 0.66, 0),
  pmar = c(3, 0.5, 0.5, 0.5),
  ...
)

Arguments

breaks

vector of break values

colors

vector of color

barlength

relative length of the bar

barlwd

line width for color bar

axislab

axis label for the colorbar

axislabline

spacing for the axis label

locut

should the lower limit represent a slanted cutoff? (boolean)

hicut

should the higher limit represent a slanted cutoff? (boolean)

slantwidth

width of the slanted cutoff as a fraction of the total bar width (numeric)

smallticks

plot small unlabeled ticks for each break (boolean)

axisbreaks

labelled break values to use in the colorbar axis

axisbreaklab

labels for the axisbreaks

tck1

length of large ticks

axiscex

cex for tick label

labelcex

cex for axis label

pmgp

temporary par 'mgp' to use

pmar

temporary par 'mar' to use

...

other arguments passed to axis function

Value

plotted colorbar


kraaijenbrink/pkrf documentation built on Nov. 14, 2020, 12:29 p.m.