ch_color_gradient {CSHShydRology}R Documentation

ch_color_gradient

Description

set colour gradient

Usage

ch_color_gradient(
  x,
  colors = c("darkred", "red", "white", "green", "darkgreen"),
  colsteps = 100,
  climits = NULL
)

Arguments

x

array of variable

colors

an array of colours to form the desired gradient. Default is ("darkred", "red", "white", "green", "darkgreen")

colsteps

number of steps to be used in gradient, default is 100.

climits

provide specific limits for common scaling

Value

vector of colors

Author(s)

Paul Whitfield

Examples

cxin <- c(0, 1, 1, 3, 4, 5, 10)
cxout <- ch_color_gradient(cxin)
#[1] "#8B0000" "#B50000" "#B50000" "#FF2B2B" "#FF9292"
#[6] "#FFF9F9" "#006400"

[Package CSHShydRology version 1.4.2 Index]