The instructions provided describe how to calculate the number of times a street segment is traversed using a network dataset and route dataset. In this example, a long route is split into shorter segments and the Spatial Join tool is used on the split routes to merge the unique ID field from the edge source attribute table to the split routes table. The unique ID field in the resulting spatial join table is summarized to get the number of times each edge is traversed.
A Network Analyst license is required to use the network dataset. Other than the ObjectID, the network edge source feature classes must contain a unique ID field such as the street centerlines.
- In ArcMap, run the Split Line at Point tool on the route layer to split the route layer into individual line segments with the parameters specified as below:
This tool requires an ArcGIS Desktop Advanced license.
- For Input Features, select the route layer from the network dataset.
- Select the junctions feature class for Point Features.
- Set the output feature class name and location.
- Specify the desired search radius and the unit of measurement.
- Click OK.
- Run the Spatial Join tool on the split routes layer to add the unique ID of the edge source to the split routes.
- For Target Features, select the split routes layer.
- For Join Features, select one of the edge source feature classes.
- Select JOIN_ONE_TO_ONE for Join Operation.
- Check the Keep All Target Features check box.
- For Match Option, select HAVE_THEIR_CENTER_IN from the drop-down list.
- Set the Search Radius to a small number (e.g. 1ft)
Skip Step 3 if there is only one network edge source in the network dataset. Unique ID fields must be the same type of field for all the network edge sources.
- Repeat the spatial join operation for any other network edge source feature classes, but change the following parameters:
- For Target Features, select the output of the previous spatial join operation.
- For Join Features, select the next edge source feature class.
- Check the Keep All Target Features check box and click OK.
- In the attribute table of the latest output from the spatial join operation, right-click the unique ID field and click Summarize.
- In the Summarize dialog box, ensure that the unique ID field is the field to summarize and click OK.
- The resulting table shows the count of how many times each edge is used.