colour_options: Display the base R colour options.

View source: R/plot.R

colour_optionsR Documentation

Display the base R colour options.

Description

display the base R colour options in the active graphics plotting device or printed to a PDF file. This makes it easier to see what the colour options are in conjunction with their R labels to make it easier to specify custom colours for plots.

Usage

colour_options(print_to_pdf = FALSE, pdf_name = "base_r_colour_options.pdf")

Arguments

print_to_pdf

IF TRUE, output is exported to a PDF in the working directory instead of displayed in an R graphics device.

pdf_name

The name of the PDF file. Default is "base_r_colour_options.pdf". Must end in .pdf. Ignored if print_to_pdf = FALSE.

Author(s)

Craig P. Hutton, Craig.Hutton@gov.bc.ca

References

Code was adapted from http://bc.bojanorama.pl/2013/04/r-color-reference-sheet/

Examples

## Not run: 
#default settings. Prints to the active graphics device.
colour_options(print_to_pdf = FALSE) #the default
colour_options(print_to_pdf = TRUE) #print to a single page PDF file in your working directory.

## End(Not run)

bcgov/elucidate documentation built on Sept. 3, 2022, 7:16 p.m.