Contour List (3D Analyst)

Available with Spatial Analyst license.

Available with 3D Analyst license.

Summary

Creates a feature class of selected contour values from a raster surface.

Learn more about how Contouring works

Usage

  • Contours do not extend beyond the spatial extent of the raster, and they are not generated in areas of NoData. Edgematch adjacent contour inputs into a continuous feature dataset first. As an alternative to edgematching, you can merge the adjacent rasters before computing contours.

  • Contours can be generated in areas of negative raster values. The contour values will be negative in such areas. Negative contour intervals are not allowed.

  • The contour values do not need to be sorted in order.

  • If you have the ArcGIS Spatial Analyst extension, smoother but less accurate contours can be obtained by preprocessing the input raster using the Focal Statistics tool with the Mean option or the Filter tool with the Low option.

  • By default, this tool will use multicore processors if available. The maximum number of cores that can be used is four.

    To use fewer cores, use the Parallel Processing Factor environment setting.

  • If the Extent environment is specified and the lower left corner of the output extent does not match any cell corner of the input raster, a shift of the cell alignment of the input raster will occur during processing to match the specified extent. This shift will trigger a resampling of the input raster using the Bilinear method. Consequently, the output features will shift as well, and the resultant output features may not overlay the original input raster exactly. You can avoid this shift by using the input raster for the Snap Raster environment.

Parameters

LabelExplanationData Type
Input raster

The input surface raster.

Raster Layer
Output polyline features

The output contour polyline features.

Feature Class
Contour values

List of z-values for which to create contours.

Double

arcpy.ddd.ContourList(in_raster, out_polyline_features, contour_values)
NameExplanationData Type
in_raster

The input surface raster.

Raster Layer
out_polyline_features

The output contour polyline features.

Feature Class
contour_values
[contour_value,...]

List of z-values for which to create contours.

Double

Code sample

ContourList example 1 (Python window)

This example creates contours for three elevation values from an Esri Grid raster and outputs them as a shapefile.

import arcpy
from arcpy import env  
env.workspace = "C:/data"
arcpy.ContourList_3d("elevation", "C:/sapyexamples/output/outcontourlist.shp", 
            "600; 935; 1237.4")
ContourList example 2 (stand-alone script)

This example creates contours for three elevation values from an Esri Grid raster and outputs them as a shapefile.

# Name: ContourList_3d_Ex_02.py
# Description: Creates contours or isolines based on a list of contour values.
# Requirements: 3D Analyst Extension

# Import system modules
import arcpy
from arcpy import env

# Set environment settings
env.workspace = "C:/data"

# Set local variables
inRaster = "elevation"
contourIntervalList = "600; 935; 1237.4"
outContours = "C:/output/outcontlist.shp"

# Execute ContourList
arcpy.ddd.ContourList(inRaster, outContours, contourIntervalList)

Licensing information

  • Basic: Requires 3D Analyst or Spatial Analyst
  • Standard: Requires 3D Analyst or Spatial Analyst
  • Advanced: Requires 3D Analyst or Spatial Analyst

Related topics