HSV: Create HSV Colors

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/colorspace.R

Description

This function creates colors of class HSV; a subclass of the virtual color-class class.

Usage

1
HSV(H, S, V, names)

Arguments

H, S, V

These arguments give the hue, saturation and value of the colors. The values can be provided in separate H, S and V vectors or in a three-column matrix passed as H.

names

A vector of names for the colors (by default the row names of H are used).

Details

This function creates colors in the HSV color space which corresponds to the standard sRGB color space (IEC standard 61966). The hues should lie between between 0 and 360, and the saturations and values should lie between 0 and 1.

Value

An object of class HSV which inherits from class color.

Author(s)

Ross Ihaka

See Also

RGB, XYZ, LAB, polarLAB, LUV, polarLUV.

Examples

1
2
# A rainbow of full-intensity hues
HSV(seq(0, 360, length = 13)[-13], 1, 1)

colorspace documentation built on May 2, 2019, 12:49 p.m.