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.

To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

Pseudocolor (checkerboard) plot

`pcolor(C)`

pcolor(X,Y,C)

pcolor(axes_handles,...)

h = pcolor(...)

A pseudocolor plot is a rectangular array of cells with colors
determined by `C`

. MATLAB^{®} creates a pseudocolor
plot using each set of four adjacent points in `C`

to
define a surface rectangle (i.e., cell).

The default `shading`

is `faceted`

,
which colors each cell with a single color. The last row and column
of `C`

are not used in this case. With `shading`

`interp`

,
each cell is colored by bilinear interpolation of the colors at its
four vertices, using all elements of `C`

.

The minimum and maximum elements of `C`

are
assigned the first and last colors in the colormap. Colors for the
remaining elements in `C`

are determined by a linear
mapping from value to colormap element.

`pcolor(C)`

draws a pseudocolor
plot. The elements of `C`

are linearly mapped to
an index into the current colormap. The mapping from `C`

to
the current colormap is defined by `colormap`

and `caxis`

.

`pcolor(X,Y,C)`

draws a
pseudocolor plot of the elements of `C`

at the locations
specified by `X`

and `Y`

. The plot
is a logically rectangular, two-dimensional grid with vertices at
the points `[X(i,j), Y(i,j)]`

. `X`

and `Y`

are
vectors or matrices that specify the spacing of the grid lines. If `X`

and `Y`

are
vectors, `X`

corresponds to the columns of `C`

and `Y`

corresponds
to the rows. If `X`

and `Y`

are
matrices, they must be the same size as `C`

.

`pcolor(axes_handles,...)`

plots into the axes with handle `axes_handle`

instead
of the current axes (`gca`

).

`h = pcolor(...)`

returns
a handle to a `surface`

graphics
object.

Was this topic helpful?