Learn R Programming

dichromat (version 1.2-1)

colorschemes: Color schemes

Description

17 color schemes suitable for people with deficient or anomalous red-green vision.

Usage

colorschemes

Arguments

format

  • BrowntoBlue.10
  • BrowntoBlue.12
  • BluetoDarkOrange.12
  • BluetoDarkOrange.18
  • DarkRedtoBlue.12
  • DarkRedtoBlue.18
  • BluetoGreen.14
  • BluetoGray.8
  • BluetoOrangeRed.14
  • BluetoOrange.10
  • BluetoOrange.12
  • BluetoOrange.8
  • LightBluetoDarkBlue.10
  • LightBluetoDarkBlue.7
  • Categorical.12
  • GreentoMagenta.16
  • SteppedSequential.5

source

Light A. and P.J. Bartlein, 2004. "The end of the rainbow? Color schemes for improved data graphics," EOS Transactions of the American Geophysical Union 85(40):385.

References

http://geography.uoregon.edu/datagraphics/color_scales.htm

Examples

Run this code
opar <- par(mar=c(1,2,1,1))
layout(matrix(1:6,ncol=1))
image(1:10,1,matrix(1:10, ncol=1),col=colorschemes$BrowntoBlue.10,
    main="Brown to Blue (10)", axes=FALSE)
image(1:100,1,matrix(1:100 ,ncol=1),col=colorRampPalette(colorschemes$BrowntoBlue.10,space="Lab")(100),
    main="Brown to Blue Ramp", axes=FALSE)
image(1:10,1,matrix(1:10, ncol=1),col=dichromat(colorschemes$BrowntoBlue.10),
   main="Brown to Blue (10) -- deuteranopia", axes=FALSE)
image(1:12,1,matrix(1:12, ncol=1),col=colorschemes$Categorical.12,main="Categorical (12)", axes=FALSE)
image(1:12,1,matrix(1:12, ncol=1),col=dichromat(colorschemes$Categorical.12),
   main="Categorical (12) -- deuteranopia", axes=FALSE)
image(1:12,1,matrix(1:12,ncol=1),col=dichromat(colorschemes$Categorical.12, "protan"),
   main="Categorical (12) -- protanopia", axes=FALSE)
par(opar)

Run the code above in your browser using DataLab