Turn Table To Turn Feature Class (Network Analyst)

Summary

Converts an ArcView turn table or ArcInfo Workstation coverage turn table to an ArcGIS turn feature class.

Usage

  • The turn feature class to be created is placed in the same workspace as the reference line feature class.

  • The coordinates in the output turn feature class will have elevation (Z) values if the reference line feature class supports Z values.

Parameters

LabelExplanationData Type
Input Turn Table

The .dbf file or INFO turn table from which the new turn feature class will be created.

Table View
Reference Line Features

The line feature class to which the input turn table refers. The feature class must be a source in a network dataset.

Feature Class
Output Turn Feature Class Name

The name of the new turn feature class to create.

String
Reference Nodes Table
(Optional)

The nodes.dbf table in the .nws folder containing the original ArcView GIS network in which the input turn table participated.

This parameter is ignored if the input turn table is an INFO table.

If the input turn table is a .dbf table and this parameter is omitted, then U-turns and turns that traverse between edges connected to each other at both ends will not be created in the output turn feature class.

Errors will be reported in an error file written to the directory defined by the TEMP system variable. The full path name to the error file is reported as a warning message.

dBASE Table
Maximum Edges
(Optional)

The maximum number of edges per turn in the new turn feature class. The default value is 5. The maximum value is 50.

Long
Configuration Keyword
(Optional)

Specifies the configuration keyword that determines the storage parameters of the output turn feature class. This parameter is used only if the output turn feature class is created in a workgroup or enterprise geodatabase.

String
Output Spatial Grid 1
(Optional)

This parameter has been deprecated in ArcGIS Pro. Any value you enter is ignored.

Double
Output Spatial Grid 2
(Optional)

This parameter has been deprecated in ArcGIS Pro. Any value you enter is ignored.

Double
Output Spatial Grid 3
(Optional)

This parameter has been deprecated in ArcGIS Pro. Any value you enter is ignored.

Double

Derived Output

LabelExplanationData Type
Output Turn Feature Class

The newly created turn feature class.

Feature Class

arcpy.na.TurnTableToTurnFeatureClass(in_turn_table, reference_line_features, out_feature_class_name, {reference_nodes_table}, {maximum_edges}, {config_keyword}, {spatial_grid_1}, {spatial_grid_2}, {spatial_grid_3})
NameExplanationData Type
in_turn_table

The .dbf file or INFO turn table from which the new turn feature class will be created.

INFO tables do not support mixed case path names on Linux and Solaris.

Table View
reference_line_features

The line feature class to which the input turn table refers. The feature class must be a source in a network dataset.

Feature Class
out_feature_class_name

The name of the new turn feature class to create.

String
reference_nodes_table
(Optional)

The nodes.dbf table in the .nws folder containing the original ArcView GIS network in which the input turn table participated.

This parameter is ignored if the input turn table is an INFO table.

If the input turn table is a .dbf table and this parameter is omitted, then U-turns and turns that traverse between edges connected to each other at both ends will not be created in the output turn feature class.

Errors will be reported in an error file written to the directory defined by the TEMP system variable. The full path name to the error file is reported as a warning message.

dBASE Table
maximum_edges
(Optional)

The maximum number of edges per turn in the new turn feature class. The default value is 5. The maximum value is 50.

Long
config_keyword
(Optional)

Specifies the configuration keyword that determines the storage parameters of the output turn feature class. This parameter is used only if the output turn feature class is created in a workgroup or enterprise geodatabase.

String
spatial_grid_1
(Optional)

This parameter has been deprecated in ArcGIS Pro. Any value you enter is ignored.

Double
spatial_grid_2
(Optional)

This parameter has been deprecated in ArcGIS Pro. Any value you enter is ignored.

Double
spatial_grid_3
(Optional)

This parameter has been deprecated in ArcGIS Pro. Any value you enter is ignored.

Double

Derived Output

NameExplanationData Type
out_turn_features

The newly created turn feature class.

Feature Class

Code sample

TurnTableToTurnFeatureClass example 1 (Python window)

Convert an ArcInfo Workstation Turn table to a turn feature class.

turn_table = "C:/Data/delayturns.trn"
network_lines = "C:/Data/SanFrancisco.gdb/Transportation/Streets"
arcpy.na.TurnTableToTurnFeatureClass(turn_table, network_lines, "DelayTurns")
TurnTableToTurnFeatureClass example 2 (Python window)

Convert an ArcView Turn Table to a turn feature class.

turn_table = "C:/Data/DelayTurns.dbf"
network_lines = "C:/Data/SanFrancisco.gdb/Transportation/Streets"
reference_nodes = "C:/Data/nodes.dbf"
arcpy.na.TurnTableToTurnFeatureClass(turn_table, network_lines, "DelayTurns",
                                        reference_nodes, 2)
TurnTableToTurnFeatureClass example 3 (stand-alone script)

The following Python script demonstrates how to use the TurnTableToTurnFeatureClass tool in a stand-alone script.

# Name: TurnTableToTurnFeatureClass_ex03.py
# Description: Converts a Arcview 3.x turn table to a turn feature class
# Requirements: Network Analyst Extension

#Import system modules
import arcpy
from arcpy import env

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

#Set local variables
inTurnTable = "C:/data/DelayTurns.dbf"
refLineFeatures = "Streets"
outTurnFeatureClassName = "DelayTurns"
maxEdges = 7

#Convert the ArcView 3.x Turn table to geodatabase turn feature class
#The streets shapefile referred by the turn features has been converted to a
#feature class in the geodatabase.
arcpy.TurnTableToTurnFeatureClass_na(inTurnTable, refLineFeatures,
                                     outTurnFeatureClassName, "", maxEdges)

print("Script completed successfully.")

Licensing information

  • Basic: Yes
  • Standard: Yes
  • Advanced: Yes

Related topics