This is documentation for Mathematica 8, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.2)

ListContourPlot

ListContourPlot[array]
generates a contour plot from an array of height values.
ListContourPlot
generates a contour plot from values defined at specified points.
  • ListContourPlot[array] arranges successive rows of array up the page, and successive columns across.
  • ListContourPlot by default generates grayscale output, in which larger values are shown lighter.
AspectRatio1ratio of height to width
BoundaryStyleNonehow to draw RegionFunction boundaries
BoxRatiosAutomaticeffective 3D bounding box ratios
ClippingStyleNonehow to draw values clipped by PlotRange
ColorFunctionAutomatichow to determine the color of regions between contour lines
ColorFunctionScalingTruewhether to scale the argument to ColorFunction
ContourLabelsAutomatichow to label contour levels
ContoursAutomatichow many or what contours to use
ContourShadingAutomatichow to shade regions between contours
ContourStyleAutomaticthe style for contour lines
DataRangeAutomaticthe range of x and y values to assume for data
FrameTruewhether to draw a frame around the plot
FrameTicksAutomaticframe tick marks
InterpolationOrderNonethe polynomial degree in each variable of the function interpolated between data points
LightingAngleNoneeffective angle of the simulated light source
MaxPlotPointsAutomaticthe maximum number of points to include
MeshNonehow many mesh lines in each direction to draw
MeshFunctions{}how to determine the placement of mesh lines
MeshStyleAutomaticthe style for mesh lines
MethodAutomaticthe method to use for interpolation and data reduction
PerformanceGoal$PerformanceGoalaspects of performance to try to optimize
PlotRange{Full,Full,Automatic}the range of f or other values to include
PlotRangeClippingTruewhether to clip at the plot range
PlotRangePaddingAutomatichow much to pad the range of values
RegionFunction(True&)how to determine whether a point should be included
  • array should be a rectangular array of real numbers; holes will be left in the plot whenever there are elements that are not real numbers.
  • ListContourPlot[array] by default takes the x and y coordinate values for each data point to be successive integers starting at 1.
  • The setting DataRange specifies other ranges of coordinate values to use.
  • ColorFunction is by default supplied with a single argument, given by the average of the scaled values of f for each pair of successive contour levels.
Generate contours from an array of heights:
Give explicit coordinates for the data:
Generate contours over interpolated data:
Generate contours from an array of heights:
In[1]:=
Click for copyable input
Out[1]=
 
Give explicit coordinates for the data:
In[1]:=
Click for copyable input
In[2]:=
Click for copyable input
Out[2]=
 
Generate contours over interpolated data:
In[1]:=
Click for copyable input
Out[1]=
For regular data consisting of values, the and data ranges are taken to be integer values:
Provide explicit and data ranges by using DataRange:
For irregular data consisting of triples, the and data ranges are inferred from data:
Areas around where the data is nonreal are excluded:
Use MaxPlotPoints to limit the number of points used:
PlotRange is selected automatically:
Use PlotRange to focus in on areas of interest:
Use RegionFunction to restrict the density to a region given by inequalities:
Add labels:
Color the density by height:
Label the contours:
Use specific colors between contours:
Use different styles for the contours:
No boundary is used by default:
Use a red boundary around the edges of the contours:
BoundaryStyle applies to holes cut by RegionFunction:
BoundaryStyle applies where there are jumps in the surface:
Clipped regions are not shown by default:
Color clipped regions like the rest of the surface:
Use pink to fill the clipped regions:
Use light red where the surface is clipped above and pink below:
Color by scaled coordinate:
Named color gradients color in the direction:
Color with blue if contour values are negative, and with red otherwise:
Add labels to contour lines:
Label with values in a frame:
Use 7 equally spaced contours:
Use automatic contour selection:
Use at most 5 automatically selected contours:
Use specific contours:
Use specific contours with specific styles:
Use a function to generate a set of contours:
Have contours at the 10% and 90% percentile values:
The automatic shading is darker at low values and lighter at high values:
Use None to only show the contour lines:
Shade between contours using a color function:
Use an explicit list of colors between contours:
The default contour style is a partially transparent line:
Use black contour lines:
Use None to not show contour lines:
Alternate between red and dashed contour lines:
Use dashed red contour lines:
Arrays of height values are displayed against the number of elements in each direction:
Rescale to the sampling space:
Triples are interpreted as coordinates:
Generate an array of triples:
Force interpretation as an array of height values:
Contours are normally based on a linear interpolation of the data:
Use zero-order or piecewise constant interpolation:
Use third-order spline interpolation to fit the data:
Interpolation order 0 to 5:
With a limited number of points, irregular data is linearly interpolated:
Irregular data with InterpolationOrder uses natural neighbor interpolation:
ListContourPlot normally uses all of the points in the dataset:
Limit the number of points used in each direction:
MaxPlotPoints imposes a regular grid on irregular data:
The grid does not extend beyond the convex hull of the original data:
Show the initial and final sampling mesh:
Use 5 mesh levels in each direction:
Use mesh lines in the and directions:
Use mesh levels corresponding to real and imaginary parts of a complex-valued function:
Use red mesh lines:
Use red mesh lines in the direction and dashed mesh lines in the direction:
Generate a higher-quality plot:
Emphasize performance, possibly at the cost of quality:
Automatically compute the range:
Use all points to compute the range:
Use an explicit range to emphasize features:
Plot over a region in :
The region depends on DataRange:
Regions do not have to be connected:
Use any logical combination of conditions:
The contours for a probability density function:
Compare to the empirical density function:
Contouring medical data:
ListContourPlot is similar to ListDensityPlot, but with bands of discrete colors:
ListContourPlot and ListPlot3D view as a function of and :
The data has only one value for each , pair:
The data has two values for each , pair:
Use ArrayPlot for arrays of discrete data:
Use MatrixPlot for structural plots of matrices:
Use ReliefPlot for matrices corresponding to medical and geographic values:
Use ListContourPlot3D to generate contour surfaces from four-dimensional data:
Use ContourPlot for functions:
Use ListPointPlot3D to show three-dimensional points:
Use ListDensityPlot to create densities from continuous data:
Use ListPlot3D to create surfaces from continuous data:
Use ListLogPlot, ListLogLogPlot, and ListLogLinearPlot for logarithmic plots:
Use ListPolarPlot for polar plots:
Use DateListPlot to show data over time:
Use ParametricPlot3D for three-dimensional parametric curves and surfaces:
The appearance may depend on the source of the data:
An ×3 matrix is by default interpreted as a list of triples:
Use DataRange->All to force interpretation as a matrix of values:
Or provide an explicit list of data ranges to force interpretation as a matrix of values:
New in 1 | Last modified in 6