Skip To Content

Intersect

Summary

Computes a geometric intersection of the input features. Features or portions of features which overlap in all layers and/or feature classes will be written to the output feature class.

Learn more about how Intersect works

Illustration

Intersect illustration

Usage

  • Input Features must be simple features: point, multipoint, line, or polygon. They cannot be complex features such as annotation features, dimension features, or network features.

  • If the inputs have different geometry types (that is, line on poly, point on line, and so on), the Output Feature Class geometry type will default to be the same as the Input Features with the lowest dimension geometry. For example, if one or more of the inputs is of type point, the default output will be point; if one or more of the inputs is line, the default output will be line; and if all inputs are polygon, the default output will be polygon.

  • The Output Type can be that of the Input Features with the lowest dimension geometry or lower. For example, if all the inputs are polygons, the output could be polygon, line, or point. If one of the inputs is of type line and none are points, the output can be line or point. If any of the inputs are point, the Output Type can only be point.

  • Attribute values from the input feature classes will be copied to the output feature class. However, if the input is a layer or layers created by the Make Feature Layer tool and a field's Use Ratio Policy is checked, then a ratio of the input attribute value is calculated for the output attribute value. When Use Ratio Policy is enabled, whenever a feature in an overlay operation is split, the attributes of the resulting features are a ratio of the attribute value of the input feature. The output value is based on the ratio in which the input feature geometry was divided. For example, If the input geometry was divided equally, each new feature's attribute value is assigned one-half of the value of the input feature's attribute value. Use Ratio Policy only applies to numeric field types.

    Caution:

    Geoprocessing tools do not honor geodatabase feature class or table field split policies.

  • This tool will use a tiling process to handle very large datasets for better performance and scalability. For more details, see Geoprocessing with large datasets.

  • This tool honors the Parallel Processing Factor environment. If the environment is not set (the default) or is set to 0, parallel processing will be disabled. Setting the environment to 100 will cause parallel processing to be enabled.

    Parallel Processing is currently supported for polygon on polygon, line on polygon and point on polygon overlay operations.

  • License:

    With ArcGIS Desktop Basic and Desktop Standard licenses, the number of input feature classes or layers is limited to two.

Syntax

Intersect_analysis (in_features, out_feature_class, {join_attributes}, {cluster_tolerance}, {output_type})
ParameterExplanationData Type
in_features
[[in_features, {Rank}],...]

A list of the input feature classes or layers. When the distance between features is less than the cluster tolerance, the features with the lower rank will snap to the feature with the higher rank. The highest rank is one. For more information, see Priority ranks and geoprocessing tools.

Value Table
out_feature_class

The output feature class.

Feature Class
join_attributes
(Optional)

Determines which attributes from the input features will be transferred to the output feature class.

  • ALLAll the attributes from the input features will be transferred to the output feature class. This is the default.
  • NO_FIDAll the attributes except the FID from the input features will be transferred to the output feature class.
  • ONLY_FIDOnly the FID field from the input features will be transferred to the output feature class.
String
cluster_tolerance
(Optional)

The minimum distance separating all feature coordinates (nodes and vertices) as well as the distance a coordinate can move in X or Y (or both).

Linear Unit
output_type
(Optional)

Choose what type of intersection you want to find.

  • INPUTThe intersections returned will be the same geometry type as the input features with the lowest dimension geometry. If all inputs are polygons, the output feature class will contain polygons. If one or more of the inputs are lines and none of the inputs are points, the output will be line. If one or more of the inputs are points, the output feature class will contain points. This is the default.
  • LINELine intersections will be returned. This is only valid if none of the inputs are points.
  • POINTPoint intersections will be returned. If the inputs are line or polygon, the output will be a multipoint feature class.
String

Code sample

Intersect example (Python window)

The following Python window script demonstrates how to use the Intersect function in immediate mode.

import arcpy
arcpy.env.workspace = "C:/data/RedRiver_basin.gdb"
arcpy.Intersect_analysis(["vegetation_stands", "road_buffer200m", "water_buffer100"], "mysites", "ALL")
arcpy.Intersect_analysis([["vegetation_stands", 2], ["road_buffer200m", 1], ["water_buffer100", 2]], "mysites_ranked", "ALL")
Intersect example 2 (stand-alone script)

The following stand-alone script uses the Intersect function as part of a workflow with other analysis tools to determine the type of vegetation within 100 meters of all stream crossings.

#Name: VegRoadIntersect.py
# Purpose: Determine the type of vegetation within 100 meters of all stream crossings

# Import system modules
import arcpy
 
# Set the workspace (to avoid having to type in the full path to the data every time)
arcpy.env.workspace = "c:/data/data.gdb"    
    
# Process: Find all stream crossings (points)
inFeatures = ["roads", "streams"]
intersectOutput = "stream_crossings"
clusterTolerance = 1.5    
arcpy.Intersect_analysis(inFeatures, intersectOutput, "", clusterTolerance, "point")
 
# Process: Buffer all stream crossings by 100 meters
bufferOutput = "stream_crossings_100m"
bufferDist = "100 meters"
arcpy.Buffer_analysis(intersectOutput, bufferOutput, bufferDist)

# Process: Clip the vegetation feature class to stream_crossing_100m
clipInput = "vegetation"
clipOutput = "veg_within_100m_of_crossings"
arcpy.Clip_analysis(clipInput, bufferOutput, clipOutput)

# Process: Summarize how much (area) of each type of vegetation is found
# within 100 meter of the stream crossings
statsOutput = "veg_within_100m_of_crossings_stats"
statsFields = [["shape_area", "sum"]]
caseField = "veg_type"
arcpy.Statistics_analysis(clipOutput, statsOutput, statsFields, caseField)

Licensing information

  • ArcGIS Desktop Basic: Limited
  • ArcGIS Desktop Standard: Limited
  • ArcGIS Desktop Advanced: Yes

Related topics