Create a profile graph and show it in multiple colors based on line segments


Instructions provided describe how to create a continuous profile graph and color the segments with different colors. An example could be to show variable surface geology represented by different colors in a continuous profile graph.



  1. Add a DEM (digital elevation model) and a 2D line, 'line_2d', with multiple segments, where each segment represents a different color (varying geology type, for example) for the profile graph.
  2. Make a copy of this line feature and merge all the features to a single feature. Name this 'line_merge'. This is used to create points.
  3. Convert the line_merge feature to a 3D line, 'line_3d', based on the DEM. In ArcToolbox, expand 3D Analyst Tools > Functional Surface > Interpolate Shape.
  1. Run the Add Z Information tool to add 3D length for the line_3d feature. In ArcToolbox, expand 3D Analyst Tools > 3D Features > Add Z Information. This 3D length can then be used to calculate the M-values.
  1. Create a Route from line_3d and call it 'route_3d'. This step is necessary as M-values are used to display the X-axis on the graph. In ArcToolbox, expand Linear Referencing Tools > Create Routes.
  1. Convert the route_3d feature into points, 'route_3d_points'. In ArcToolbox, expand Data Management Tools > Features > Feature Vertices to Points.
  1. Open the Add XY coordinates tool and run it for route_3d_points. In ArcToolbox, expand Data Management Tools > Features > Add XY Coordinates. This tool adds X, Y, Z and M values to the point features.
  1. Intersect the route_3d_points feature with line_2d and name it 'point_3d_intersect'. In ArcToolbox, expand Analysis Tools > Overlay > Intersect. This adds a unique ID to route_3d_points based on line segments of line_2d.
  1. Symbolize the point_3d_intersect points with unique values (line segment ID).
  2. Create a graph (View > Graphs > Create) from the menu bar.
  • Graph type: Vertical Line
  • Select Layer/Table: point_3d_intersect
  • Make adjustments to title, legend, etc.

Article ID:000011317

  • ArcMap 10 x

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options

Related Information

Discover more on this topic