Learn R Programming

ContourFunctions (version 0.1.2)

cm.colors.strong: Strong version of cm.colors color palette

Description

Altered version of cm.colors that uses full saturation to get stronger colors.

Usage

cm.colors.strong(n, alpha = 1)

Value

Character vector of colors

Arguments

n

Number of color groups

alpha

Alpha level

Examples

Run this code
# Character string output
cm.colors.strong(5)

# Plot to show these
sl <- 21
sx <- seq(0,1,l=sl)
plot(sx,sin(2*pi*sx), cex=5, col=cm.colors.strong(sl), pch=19);points(sx,sin(2*pi*sx), cex=5)
plot(sx,sin(2*pi*sx), cex=5, col=cm.colors(sl),        pch=19);points(sx,sin(2*pi*sx), cex=5)

Run the code above in your browser using DataLab