Learn R Programming

palr (version 0.4.0)

sst_pal: SST colours

Description

SST colours

Usage

sst_pal(x, palette = FALSE, alpha = 1, ...)

sstPal(x, palette = FALSE, alpha = 1, ...)

Value

colours, palette, or function, see Details

Arguments

x

a vector of data values or a single number

palette

logical, if TRUE return a list with matching colours and values

alpha

value in 0,1 to specify opacity

...

currently ignored

References

Derived from a file once found at 'http://oceancolor.gsfc.nasa.gov/DOCS/palette_sst.txt'

Examples

Run this code
data(oisst)
sstcols <- sst_pal(palette = TRUE)
image(oisst, col = sstcols$col, zlim = range(sstcols$breaks))

Run the code above in your browser using DataLab