Show Navigation | Hide Navigation
You are here:
Geoprocessing tool reference > Linear Referencing toolbox > Tools

Calibrate Routes (Linear Referencing)

Release 9.2
Last modified November 9, 2006
E-mail This Topic Printable Version Give Us Feedback

Print all topics in : "Tools"


Related Topics

Recalculates route measures using points.


Usage tips

Command line syntax
An overview of the Command Line window
CalibrateRoutes_lr <in_route_features> <route_id_field> <in_point_features> <point_id_field> <measure_field> <out_feature_class> {DISTANCE | MEASURES} {search_radius} {BETWEEN | NO_BETWEEN} {BEFORE | NO_BEFORE} {AFTER | NO_AFTER} {IGNORE | NO_IGNORE} {KEEP | NO_KEEP} {INDEX | NO_INDEX}

Parameter Explanation Data Type
<in_route_features>

The route features to be calibrated.

Feature Layer
<route_id_field>

The field containing values that uniquely identify each route. This field can be numeric or character.

Field
<in_point_features>

The point features used to calibrate the routes.

Feature Layer
<point_id_field>

The field that identifies the route on which each calibration point is. The values in this field match those in the route identifier field. This field can be numeric or character.

Field
<measure_field>

The field containing the measure value for each calibration point. This field must be numeric.

Field
<out_feature_class>

The feature class to be created. It can be a shapefile or a geodatabase feature class.

Feature Class
{DISTANCE | MEASURES}

Specifies how route measures will be recalculated.

  • DISTANCE — Measures will be recalculated using the shortest path distance between the calibration points. This is the default.
  • MEASURES — Measures will be recalculated using the pre-existing measure distance between the calibration points.

String
{search_radius}

Limits how far a calibration point can be from a route by specifying the distance and its unit of measure. If the units of measure are Unknown, the same units as the coordinate system of the route feature class will be used.

Linear unit
{BETWEEN | NO_BETWEEN}

Specifies whether measure values will be interpolated between the calibration points.

  • BETWEEN — Interpolate between the calibration points. This is the default.
  • NO_BETWEEN — Do not interpolate between the calibration points.

Boolean
{BEFORE | NO_BEFORE}

Specifies whether measure values will be extrapolated before the calibration points.

  • BEFORE — Extrapolate before the calibration points. This is the default.
  • NO_BEFORE — Do not extrapolate before the calibration points.

Boolean
{AFTER | NO_AFTER}

Specifies whether measure values will be extrapolated after the calibration points.

  • AFTER — Extrapolate after the calibration points. This is the default.
  • NO_AFTER — Do not extrapolate after the calibration points.

Boolean
{IGNORE | NO_IGNORE}

Specifies whether spatial gaps will be ignored when recalculating the measures on disjointed routes.

  • IGNORE — Spatial gaps will be ignored. Measure values will be continuous for disjointed routes. This is the default.
  • NO_IGNORE — Do not ignore spatial gaps. The measure values on disjointed routes will have gaps. The gap distance is calculated using the straight-line distance between the endpoints of the disjointed parts.

Boolean
{KEEP | NO_KEEP}

Specifies whether route features that do not have any calibration points will be excluded from the output feature class.

  • KEEP — Keep all route features in the output feature class. This is the default.
  • NO_KEEP — Do not keep all route features in the output feature class. Features that have no calibration points will be excluded.

Boolean
{INDEX | NO_INDEX}

Specifies whether an attribute index will be created for the route identifier field that is written to the Output Route Feature Class.

  • INDEX — Create an attribute index. This is the default.
  • NO_INDEX — Do not create an attribute index.

Boolean
Data types for geoprocessing tool parameters


Command line example

Workspace "C:\Data"
CalibrateRoutes_lr hwy.shp route1 cal_pts.shp route1 measure hwy_new DISTANCE "5.0 feet" BETWEEN BEFORE AFTER # NO_KEEP

Workspace "C:\Data\Pitt.mdb"
CalibrateRoutes_lr roads\hwy route1 roads\cal_pts route1 measure roads\hwy_new DISTANCE "2.5 meters" BETWEEN NO_BEFORE NO_AFTER

Workspace "C:\Data\Pitt.gdb"
CalibrateRoutes_lr roads\hwy route1 roads\cal_pts route1 measure roads\hwy_new DISTANCE "2.5 meters" BETWEEN BEFORE AFTER

Workspace "Database Connections\Connection to Jerry.sde"
CalibrateRoutes_lr gdb.hwy route1 gdb.cal_pts route1 measure hwy_new DISTANCE "5.0 feet" # # # # NO_KEEP

Scripting syntax
About getting started with writing geoprocessing scripts
CalibrateRoutes_lr (in_route_features, route_id_field, in_point_features, point_id_field, measure_field, out_feature_class, calibrate_method, search_radius, interpolate_between, extrapolate_before, extrapolate_after, ignore_gaps, keep_all_routes, build_index)

Parameter Explanation Data Type
in_route_features (Required)

The route features to be calibrated.

Feature Layer
route_id_field (Required)

The field containing values that uniquely identify each route. This field can be numeric or character.

Field
in_point_features (Required)

The point features used to calibrate the routes.

Feature Layer
point_id_field (Required)

The field that identifies the route on which each calibration point is. The values in this field match those in the route identifier field. This field can be numeric or character.

Field
measure_field (Required)

The field containing the measure value for each calibration point. This field must be numeric.

Field
out_feature_class (Required)

The feature class to be created. It can be a shapefile or a geodatabase feature class.

Feature Class
calibrate_method (Optional)

Specifies how route measures will be recalculated.

  • DISTANCE — Measures will be recalculated using the shortest path distance between the calibration points. This is the default.
  • MEASURES — Measures will be recalculated using the pre-existing measure distance between the calibration points.

String
search_radius (Optional)

Limits how far a calibration point can be from a route by specifying the distance and its unit of measure. If the units of measure are Unknown, the same units as the coordinate system of the route feature class will be used.

Linear unit
interpolate_between (Optional)

Specifies whether measure values will be interpolated between the calibration points.

  • BETWEEN — Interpolate between the calibration points. This is the default.
  • NO_BETWEEN — Do not interpolate between the calibration points.

Boolean
extrapolate_before (Optional)

Specifies whether measure values will be extrapolated before the calibration points.

  • BEFORE — Extrapolate before the calibration points. This is the default.
  • NO_BEFORE — Do not extrapolate before the calibration points.

Boolean
extrapolate_after (Optional)

Specifies whether measure values will be extrapolated after the calibration points.

  • AFTER — Extrapolate after the calibration points. This is the default.
  • NO_AFTER — Do not extrapolate after the calibration points.

Boolean
ignore_gaps (Optional)

Specifies whether spatial gaps will be ignored when recalculating the measures on disjointed routes.

  • IGNORE — Spatial gaps will be ignored. Measure values will be continuous for disjointed routes. This is the default.
  • NO_IGNORE — Do not ignore spatial gaps. The measure values on disjointed routes will have gaps. The gap distance is calculated using the straight-line distance between the endpoints of the disjointed parts.

Boolean
keep_all_routes (Optional)

Specifies whether route features that do not have any calibration points will be excluded from the output feature class.

  • KEEP — Keep all route features in the output feature class. This is the default.
  • NO_KEEP — Do not keep all route features in the output feature class. Features that have no calibration points will be excluded.

Boolean
build_index (Optional)

Specifies whether an attribute index will be created for the route identifier field that is written to the Output Route Feature Class.

  • INDEX — Create an attribute index. This is the default.
  • NO_INDEX — Do not create an attribute index.

Boolean

Data types for geoprocessing tool parameters


Script example

# Example 1:
#   Calibrate shapefile routes using shapefile points.

import arcgisscripting, constants
gp = arcgisscripting.create()
try:
    gp.Workspace = "C:/Data"
    rts = "hwy.shp"
    rid = "ROUTE1"                     # used for both route-id and point-id
    pts = "cal_pts.shp"
    mfield = "MEASURE"
    radius = "5.0 Feet"
    out_fc = "hwy_new"                 # new shapefile that will be created
    gp.CalibrateRoutes_lr (rts, rid, pts, rid, mfield, out_fc, "DISTANCE", radius,                            "BETWEEN", "BEFORE", "AFTER", "#", "NO_KEEP")
except:
    print gp.GetMessages(2)


# Example 2:
#   Calibrate personal geodatabase routes with file geodatabase points.

import arcgisscripting, constants
gp = arcgisscripting.create()
try:
    gp.Workspace = "C:/Data/Pitt.gdb"
    rts = "roads/hwy" #hwy is in the roads feature dataset
    rid = "ROUTE1" 
    pts = "roads/cal_pts"               # cal_pts is in the roads feature dataset
    mfield = "MEASURE"
    radius = "2.5 Meters"
    out_fc = "roads/hwy_new"            # new feature class in a feature dataset
    gp.CalibrateRoutes_lr (rts, rid, pts, rid, mfield, out_fc, "DISTANCE", radius,                            "BETWEEN", "NO_BEFORE", "NO_AFTER")
except:
    print gp.GetMessages(2)


# Example 3:
#   Calibrate personal geodatabase routes with personal geodatabase points.
import arcgisscripting, constants
gp = arcgisscripting.create()
try:
    gp.Workspace = "C:/Data/Pitt.mdb"
    rts = "roads/hwy" #hwy is in the roads feature dataset
    rid = "ROUTE1" 
    pts = "roads/cal_pts"                 # cal_pts is in the roads feature dataset
    mfield = "MEASURE"
    radius = "2.5 Meters"
    out_fc = "roads/hwy_new"              # new feature class in a feature dataset
    gp.CalibrateRoutes_lr (rts, rid, pts, rid, mfield, out_fc, "DISTANCE", radius,                            "BETWEEN", "NO_BEFORE", "NO_AFTER")
except:
    print gp.GetMessages(2)


# Example 4:
#   Calibrate enterprise geodatabase routes using enterprise geodatabase points.
import arcgisscripting, constants
gp = arcgisscripting.create()
try:
    wkspc = "Database Connections/Connection to Jerry.sde"
    gp.Workspace = wkspc 
    rts = gp.QualifyTableName("hwy", wkspc)         # standalone feature class
    rid = "ROUTE1"
    pts = gp.QualifyTableName("cal_pts", wkspc)     # standalone feature class
    mfield = "MEASURE"
    radius = "5.0 Feet"
    out_fc = "hwy_new" #new standalone feature class 
    gp.CalibrateRoutes_lr (rts, rid, pts, rid, mfield, out_fc, "DISTANCE", radius,                            "#", "#", "#", "#", "NO_KEEP")
except:
    print gp.GetMessages(2)

Please visit the Feedback page to comment or give suggestions on ArcGIS Desktop Help.
Copyright © Environmental Systems Research Institute, Inc.