Learn R Programming

colortools (version 0.1.5)

splitComp: Split Complementary Color Scheme

Description

The split-complementary color scheme is a variation of the complementary color scheme. It uses the two colors adjacent to its complement.

Usage

splitComp(color, plot = TRUE, bg = "white", labcol = NULL, cex = 0.8, title = TRUE)

Arguments

color
an R color name of a color in hexadecimal notation
plot
logical value indicating whether to plot a color wheel with the generated scheme
bg
background color of the plot. Used only when plot=TRUE
labcol
color for the labels (i.e. names of the colors). Used only when plot=TRUE
cex
numeric value indicating the character expansion of the labels
title
logical value indicating whether to display a title in the plot. Unsed only when plot=TRUE

Value

A character vector with the given color and the split-complementary colors in hexadecimal notation

Details

This color scheme has the same strong visual contrast as the complementary scheme, but it is supposed to have less tension.

See Also

complementary

Examples

Run this code
# split-complementary colors of 'tomato' (no plot)
splitComp("tomato", plot = FALSE)

# split-complementary colors of 'tomato' (with dark gray background)
splitComp("tomato", bg = "gray40")

Run the code above in your browser using DataLab