Documentation

contourc

低级等高线图computation

Syntax

C = contourc(Z)
C = contourc(Z,n)
C = contourc(Z,v)
C = contourc(x,y,Z)
C = contourc(x,y,Z,n)
C = contourc(x,y,Z,v)

Description

contourccalculates the contour matrixCused bycontour,contour3, andcontourf. The values inZdetermine the heights of the contour lines with respect to a plane. The contour calculations use a regularly spaced grid determined by the dimensions ofZ.

C = contourc(Z)computes the contour matrix from data in matrixZ, whereZmust be at least a 2-by-2 matrix. The contours are isolines in the units ofZ. The number of contour lines and the corresponding values of the contour lines are chosen automatically.

C = contourc(Z,n)computes contours of matrixZwithncontour levels.

C = contourc(Z,v)computes contours of matrixZwith contour lines at the values specified in vectorv. The length ofvdetermines the number of contour levels. To compute a single contour of levelk, usecontourc(Z,[k k]).

C = contourc(x,y,Z),C = contourc(x,y,Z,n), andC = contourc(x,y,Z,v)compute contours ofZusing vectorsxandyto determine thexandyvalues.xandymust be monotonically increasing.

Tips

For more information on the contour matrix, see theContourMatrixproperty for contour objects.

Specifying irregularly spacedxandyvectors is not the same as contouring irregularly spaced data. Ifxoryis irregularly spaced,contourccalculates contours using a regularly spaced contour grid, then transforms the data toxory.

Introduced before R2006a

Was this topic helpful?