This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.


View and modify colormap, control color scaling, add colorbar


colormap View and set current colormap
colormapeditor Open colormap editor
colorbar Colorbar showing color scale
brighten Brighten or darken colormap
contrast Grayscale colormap for contrast enhancement
shading Set color shading properties
graymon Set default figure properties for grayscale monitors
caxis Color axis scaling
hsv2rgb Convert HSV colormap to RGB colormap
rgb2hsv Convert RGB colormap to HSV colormap
rgbplot Plot colormap
spinmap Spin colormap
colordef Set default property values to display different color schemes
whitebg Change axes background color


Colorbar Properties Control colorbar appearance and behavior

Examples and How To

Programmatic Workflow

Change Colorbar Width

This example shows how to change the width of the colorbar by setting its Position property.

Change Mapping of Data Values into Colormap

This example shows how to control the mapping of data values to colors in the colormap so that negative data values map to black.

Tools Workflow

Add Colorbar to Graph Interactively

This example shows how to interactively add a colorbar to a graph that shows the current colormap.


Coloring Mesh and Surface Plots

There are several techniques for coloring surface and mesh plots, including colormaps, truecolor, and texture mapping.

Specifying Patch Coloring

Specify patch coloring if you do not want the default white face color and black edge color. Specify the coloring using various patch properties.

Interpreting Indexed and Truecolor Data

Patch color data is interpreted as either indexed color data or truecolor data.

Was this topic helpful?