colscal: Generate a color scale

View source: R/colorscale.R

colscalR Documentation

Generate a color scale

Description

Generate a vector of colors

Usage

colscal(
  n = 14,
  pal = "t2m",
  rev = FALSE,
  alpha = NULL,
  test = FALSE,
  verbose = FALSE
)

Arguments

n

length of color vector

pal

color palette: "bwr",rwb","faint.bwr","faint.rwb","rainbow","gray.colors","heat.colors", "terrain.colors","topo.colors","cm.colors","grmg","brbu","budor","budrd","bugr","bugy","buor", "buorr","bu","rd","brgrbu","grwbu","burd","buyrd","cat","cold", "warm", "t2m", "precip", "fw", "mu", "precip.kin2100", "precip.trend.kin2100", "t2m.kin2100"

rev

a boolean; if TRUE reverse color scale

alpha

factor defining transparency of color

test

a boolean; if TRUE show a sample of the color scale

verbose

a boolean; if TRUE print information about progress

Details

Palette options are as follows: 't2m': blue-yellow-red (from seNorge), 'precip', 'mu' and 'fw': white-blue (from seNorge), 'cold': a cold color scale (from seNorge), 'warm': a warm color scale (from seNorge), 't2m.IPCC': blue-red color scale from the IPCC visual guide for authors from 2019 'precip.IPCC': green-brown colros scale from the IPCC visual guide for authors from 2019 't2m.kin2100': blue-red color scale from Klima i Norge 2100 (KiN2100) 'precip.kin2100': brown-green-blue color scale (from KiN2100) 'precip.trend.kin2100': green-white-blue color scale (from KiN2100) 'cold.kin2100': a cold color scale (from KiN2100), 'warm.kin2100': a warm color scale (from KiN2100), 'bwr' (blue-white-red), 'slp' and 'mslp' (same as 'bwr'), 'rwb' (red-white-blue), 'faint.rwb': fainter version of 'rwb', 'faint.bwr': fainter version of 'bwr', 'grmg': green-magenta, 'brbu': brown-blue, 'budor': blue-orange, 'budrd': blue-red, 'bugr': blue-green, 'bugy': blue-gray, 'buor': blue-orange (brighter colors than 'budor'), 'buorr': blue-green (brighter and more yellow than 'buor' and 'budor'), 'bu': blues, 'rd': reds, 'brgrbu': brown-green-blue, same as precip.kin2100 'grwbu': green-white-blue, same as precip.trend.kin2100 'burd': blue-red, same as t2m.kin2100 'buyrd': blue-yellow-red, same as t2m 'cat': categorical color scale, color scales from grDevices: 'rainbow', 'gray.colors', 'heat.colors', 'terrain.colors', 'topo.colors', and 'cm.colors'.

See Also

colbar col.bar colbar.ini


metno/esd documentation built on April 29, 2024, 3:34 p.m.