Axis labels are determined by the range of X , Y , and Z , or by the current setting of axis . The color scaling is determined by the range of C , or by the current setting of caxis . The scaled color values are used as indices into the current colormap. Z , so color is proportional to surface height. Note that x corresponds to the columns of Z and y corresponds to the rows.
Examples Produce a combination mesh and contour plot of the peaks surface.
If you need additional control over the appearance of the contours, you can issue these commands directly. You can also combine other types of graphs in this manner, for example surf and pcolor plots. Limitations meshc assumes that vectors x and y are monotonically increasing. If x and y are irregularly spaced, the contours are simply stretched apart, which is not the same as contouring the irregularly spaced data. Copyright 1994 by The MathWorks, Inc.