rgb(red, green, blue, alpha = NULL, names = NULL, maxColorValue = 1)
red |
numbers between 0 and maxColorValue giving the amount of redness in the colors.
If red is a 3-column matrix or data.frame and the green and blue arguments are omitted, then its columns will be used as the usual red, green, and blue arguments. |
green | numbers between 0 and maxColorValue giving the amount of greenness in the colors. |
blue | numbers between 0 and maxColorValue giving the amount of blueness in the colors. |
alpha | numbers between 0 and maxColorValue giving the amount of opacity in the colors. If NULL, the default, the colors will be fully opaque. |
names | a character vector (or NULL) giving the names for the output vector. |
maxColorValue | a positive number giving the scale for the color and alpha values. |
rgb(red=c(1,.8), green=c(0,.8), blue=c(0,0), alpha=.4, names=c("redTint", "yellowTint")) rgb(cbind(c(1,.8), c(0,.8), c(0,0)), alpha=.4, names=c("redTint", "yellowTint"))