gray
Palette of Grays

Description

Generates gray colors.

Usage

gray(level, alpha = NULL)
grey(level, alpha = NULL)

Arguments

level a vector of numbers between 0 and 1 specifying the darkness of the desired grays.
alpha a number or a vector of length(level) numbers between 0 and 1 specifying the opacity of the grays. If NULL (the default), the opacity is not included in the color string.
Value
returns a color string for each level with the red, green, and blue values equal.
The color strings have the format "#RRGGBB" or "#RRGGBBAA" where the XX are two digit hexadecimal values (range 00-FF) for the red, green, blue, and possible alpha (opacity) components of the colors.
Note
grey and gray are two names for the same function.
See Also
gray.colors, rgb.
Examples
gray(seq(0.5, 1, len=5))
Package grDevices version 6.0.0-69
Package Index