powered by
set colour gradient
ch_color_gradient( x, colors = c("darkred", "red", "white", "green", "darkgreen"), colsteps = 100, climits = NULL )
vector of colors
array of variable
an array of colours to form the desired gradient. Default is ("darkred", "red", "white", "green", "darkgreen")
number of steps to be used in gradient, default is 100.
provide specific limits for common scaling
Paul Whitfield
cxin <- c(0, 1, 1, 3, 4, 5, 10) cxout <- ch_color_gradient(cxin) #[1] "#8B0000" "#B50000" "#B50000" "#FF2B2B" "#FF9292" #[6] "#FFF9F9" "#006400"
Run the code above in your browser using DataLab