swatch: Simple colour swatches

swatchR Documentation

Simple colour swatches

Description

This function provides a simple visualisation of a colour series as a series of boxes against the specified background colour. If the input has more than one dimension then the boxes will be arranged in a grid (flattening further dimensions after the second).

Usage

swatch(x, bg = "white", ...)

Arguments

x

One or more colours, in any suitable form (see shade).

bg

A background colour.

...

Additional arguments (currently unused).

Author(s)

Jon Clayden code@clayden.org

Examples

swatch(c("red", "green", "blue"))

jonclayden/shades documentation built on Oct. 17, 2024, 4:52 p.m.