colorspace (version 2.1-0)

coords: Extract the Numerical Coordinates of a Color

Description

This function returns a matrix with three columns which give the coordinates of a color in its natural color space.

Usage

coords(color)

Value

A numeric matrix giving the coordinates of the color.

Arguments

color

A color.

Author

Ross Ihaka

See Also

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

Examples

Run this code
x <- sRGB(1, 0, 0)
coords(as(x, "HSV"))

Run the code above in your browser using DataLab