Resolve Road Conflicts (Cartography)
Summary
Resolves graphic conflicts among symbolized road features by adjusting portions of line segments.
Learn more about how Resolve Road Conflicts works
This tool does not produce output layers but instead alters the source feature classes of the input layers. If the input layers are drawn with a representation (whose editing behavior is set to store shape overrides), the modified features are stored as shape overrides in the representation. If the layer is not drawn with a representation, the geometry of the input features is modified. Using representations is recommended when working with the conflict resolution tools. That way, if the results are not acceptable, or to rerun the tool with different parameters, simply remove the overrides using the Remove Override tool. It is strongly suggested that you make a copy of your input features if you are not using representations whose editing behavior is set to store shape overrides.
A warning is raised if the input features are not in a projected coordinate system. This tool relies on linear distance units, which will create unexpected results in an unprojected coordinate system. It is strongly suggested that you run this tool on data in a projected coordinate system to ensure valid results. An error is raised and the tool will not process if the coordinate system is missing or unknown.
Illustration
Usage
-
This tool is typically used when producing relatively large-scale products where it is preferable to display divided roads with multiple lanes that are visually distinct. At smaller scales, you may want to use the Merge Divided Roads tool to display a single representative line for these features instead. If your workflow includes running both tools on the same collection of roads, it is advisable to merge roads prior to resolving road conflicts.
-
The Hierarchy Field parameter is used to specify the hierarchical importance of each road class. Lower integers specify more significant roads, with hierarchy equal to 1 for the most important roads. Movement will be minimized for the most important roads; lower hierarchy roads generally will be moved to accommodate higher hierarchy roads. The hierarchy field must be present and named the same for all input feature classes.
-
This tool operates by assessing graphic conflicts of symbolized features. The symbology extent and the reference scale are considered in conjunction with one another. Run this tool only after you have finalized the appearance of your symbols and ensure that the reference scale corresponds to the final intended output scale.
An error will be raised if line and outline symbol widths equal zero. To eliminate certain features from display, consider using a definition query on the layer.
-
You can lock features from displacement by calculating the Hierarchy Field value equal to 0 (zero). This is useful when a road should not be moved because of its a spatial relationship with other map features, especially continuous data like elevation, and should not be moved.
Processing large road datasets or a number of datasets together may exceed memory limitations. In this case, consider processing input data by partition by identifying a relevant polygon feature class in the Cartographic Partitions environment setting. Portions of the data, defined by partition boundaries, will be processed sequentially. The resulting feature classes will be seamless and consistent at partition edges. See How Resolve Road Conflicts works for more information about running this tool with partitioning.
-
The optional Output Displacement Feature Class parameter creates a feature class of polygons that indicates the amount and direction of displacement that took place. This feature class can be used for visual inspection, for spatial querying, or as an input to the Propagate Displacement tool.
Syntax
Parameter | Explanation | Data Type |
in_layers [in_layers,...] |
The input feature layers containing symbolized road features that may be in conflict. | Layer |
hierarchy_field |
The field that contains hierarchical ranking of feature importance, where 1 is very important and larger integers reflect decreasing importance. A value of 0 (zero) locks the feature to ensure that it is not moved. The hierarchy field must be present and named the same for all input feature classes. | String |
out_displacement_features (Optional) |
The output polygon features containing the degree and direction of road displacement, to be used by the Propagate Displacement tool to preserve spatial relationships. | Feature Class |
Code Sample
The following Python window script demonstrates how to use the ResolveRoadConflicts tool in immediate mode.
import arcpy
from arcpy import env
env.workspace = "C:/data"
env.referenceScale = "50000"
arcpy.ResolveRoadConflicts_cartography("C:/data/roads.lyr;C:/data/streets.lyr;C:/data/highways.lyr",
"hierarchy", "C:/data/cartography.gdb/transportation/displace")
This stand-alone script shows an example of using the ResolveRoadConflicts tool.
# Name: ResolveRoadConflicts_standalone_script.py
# Description: Resolves symbology conflicts between roads by separating them apart from each other
# Author: ESRI
# Import system modules
import arcpy
from arcpy import env
# Set environment settings
env.workspace = "C:/data"
env.referenceScale = "50000"
# Set local variables
in_layers = "C:/data/roads.lyr;C:/data/streets.lyr;C:/data/highways.lyr"
hierarchy_field = "hierarchy"
out_displacement_features = "C:/data/cartography.gdb/transportation/displace"
# Execute Resolve Road Conflicts
arcpy.ResolveRoadConflicts_cartography(in_layers, level_field, out_displacement_features)