Navigation

Operators and Keywords

Function List:

C++ API

: map = colorcube ()
: map = colorcube (n)

Create color colormap. This colormap is composed of as many equally spaced colors (not grays) in the RGB color space as possible.

If there are not a perfect number n of regularly spaced colors then the remaining entries in the colormap are gradients of pure red, green, blue, and gray.

The argument n must be a scalar. If unspecified, the length of the current colormap, or 64, is used.

See also: colormap.

Demonstration 1

The following code

 ## Show the 'colorcube' colormap as an image
 image (1:64, linspace (0, 1, 64), repmat ((1:64)', 1, 64));
 axis ([1, 64, 0, 1], "xy");
 set (gca, "xtick", []);
 colormap (colorcube (64));

Produces the following figure

Figure 1

Package: octave