Points To Track Segments (Intelligence)

Summary

Converts a series of output paths from time-enabled sequences of input point data, such as GPS points.

Usage

  • If the Input Features parameter is in a projected coordinate system, the Output Feature Class parameter will use the same coordinate system. If the Input Features parameter is in a geographic coordinate system, the Output Feature Class parameter will use Web Mercator.

  • If duplicate points exist in the Input Features, in other words, the coordinates are the same for two or more points, a 1-centimeter offset is added to the second y-coordinate when each output line is created. This is because the geometry model does not allow for duplicate vertices in a single polyline.

  • When Input Features are projected to Web Mercator, there may be discrepancies between the values in the Shape Length and Distance fields because the Distance field values are calculated using a geodesic length and are considered more accurate.

  • In addition to the field specified in the Group Field parameter, the following fields are added to the Output Feature Class parameter:

    Field nameField aliasDescription
    dstartStart Date

    Starting date and time

    dendEnd Date

    Ending date and time

    distanceDistance (m)

    Distance in meters

    delta_secondsTime Delta (s)

    Time difference in seconds

    delta_minutesTime Delta (m)

    Time difference in minutes

    speed_meters_per_secondSpeed (m/s)

    Speed in meters per second

    speed_mphSpeed (mi/h)

    Speed in miles per hour

    speed_kilometers_per_hourSpeed (km/h)

    Speed in kilometers per hour

    speed_knotsSpeed (knots)

    Speed in knots

  • An output .lyrx file (symbology and layer settings) is created for the Output Feature Class and Output Sequence Points. These are created in the nearest folder workspace that contains the output features.

Syntax

PointsToTrackSegments(in_features, date_field, out_feature_class, {group_field}, {include_velocity}, {out_point_feature_class})
ParameterExplanationData Type
in_features

Point features as point positions along the tracks to be created.

Feature Layer
date_field

The date field used to order the Input Features points.

Field
out_feature_class

The output track line features.

Feature Class
group_field
(Optional)

A field from the Input Features used to group the input points. Each unique group will create a separate track.

Field
include_velocity
(Optional)

Specifies whether output velocity fields speed_meters_per_second, speed_mph, speed_kilometers_per_hour, and speed_knots) will be included in the out_feature_class.

  • INCLUDE_VELOCITYOutput velocity fields will be added to the output. This is the default.
  • EXCLUDE_VELOCITYOutput velocity fields will not be added to the output.
Boolean
out_point_feature_class
(Optional)

The output point features. The output will include a SEQUENCE field that contains the order used for the path created in the Output Feature Class.

Feature Class

Code sample

PointsToTrackSegments example 1 (Python window)

The following Python window script demonstrates how to use the PointsToTrackSegments function in immediate mode:

import arcpy

arcpy.PointsToTrackSegments_intelligence("C:/data/mtracks.gdb/source_pts", 
                                         "DateTime", 
                                         "C:/data/mtracks.gdb/tracklines", 
                                         "Name",
																																									"INCLUDE_VELOCITY",
																																									"C:/data/mtracks.gdb/seqpoints")
PointsToTrackSegments example 2 (stand-alone script)

The following Python script demonstrates how to use the PointsToTrackSegments function in a stand-alone script:

# Name: PointsToTrackSegments_Example2.py
# Description: Convert points to track segments.

# Import system modules
import arcpy 

# Set local variables
in_features = "C:/data/mtracks.gdb/source_pts"
date_time = "DateTime"
out_feature_class = "C:/data/mtracks.gdb/tracklines"
group_field = "Name" 
out_points = "C:/data/mtracks.gdb/seqpoints"

# Execute PointsToTrackSegments
arcpy.PointsToTrackSegments_intelligence(in_features, date_time, 
                                         out_feature_class, group_field,
                                         "INCLUDE_VELOCITY", out_points)

Environments

This tool does not use any geoprocessing environments.

Licensing information

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

Related topics