Skip to content
Prev 32710 / 63424 Next

Colour Schemes

This is basically what ggplot2 does behind the scenes, with the slight
addition that scales also know how to be "trained", so that the domain
can be learned from the data:

sc <- scale_colour_gradient()
sc$train(1:10)
sc$map(1:10)

Hadley