colorramp {arrayMagic}R Documentation

colorramp

Description

Returns a function which allows to create color ramps.

Arguments

palette vector, defining a color palette

Value

A function with a single argument n to specify the length of the desired color ramp.

Author(s)

Examples

   RdBu11 <- c("#67001F", "#B2182B", "#D6604D", "#F4A582", "#FDDBC7",
               "#F7F7F7", "#D1E5F0", "#92C5DE", "#4393C3", "#2166AC", "#053061")
   finerGraded <- colorramp(RdBu11)(33)
   barplot(rep(1,33), col=finerGraded)
        

[Package Contents]