SETCOLORMAP

Purpose:

Sets the colormap for density and shaded plots.

Syntax:

SETCOLORMAP(map)

map

-

An Nx3 array of RGB (red, green blue) triples.

Returns:

Nothing.

Example:

all = (0..255)/255

zip = zeros(255, 1);

 

map1 = ravel(all, all, all);

map2 = ravel(all, zip, all);

map3 = ravel(all, all, zip);

 

setcolormap(map1);showcmap();

 

creates and displays a black to white colormap.

 

setcolormap(map2);showcmap();

 

creates and displays a black to magenta colormap.

 

setcolormap(map2);showcmap();

 

creates and displays a black to yellow colormap.

Remarks:

The colormap must be an array of N rows by 3 columns where 1 <= N <= 255. Each individual RGB (red, green, blue) value is a real number ranging from 0 to 1.0.

 

See DEFCOLOR to define a single color.

See Also:

COOL

COPPER

DEFCOLOR

GETCOLORMAP

GETCRANGE

GRAY

HOT

RAINBOW

SETCRANGE

SETPALETTE

SETPMAP

SHOWCMAP