Learn R Programming

mcmcplots (version 0.2)

mcmcplotsPalette: Color Palette for the mcmcplots Package

Description

This function uses the colorspace package to create a color palette for the functions in the mcmcplots package.

Usage

mcmcplotsPalette(n, seq = FALSE)

Arguments

n
number of colors
seq
logical indicating whether to use "sequential" colors rather than "rainbow" colors

Value

  • A color palette of n colors.

Details

None.

References

Zeileis, A., Hornik, K. and Murrell, P. (2009) "Escaping RGBland: Selecting colors for statistical graphs." Compuational Statistics & Data Analysis, 53, 3259--3270.

See Also

rainbow_hcl, sequential_hcl

Examples

Run this code
colorpie <- function(n) pie(rep(1, n), col=mcmcplotsPalette(n))
colorpie(1)
colorpie(8)

Run the code above in your browser using DataLab