Skip to main content

Make Vehicle Routing Problem Analysis Layer (Network Analyst Tools)

Summary

Creates a vehicle routing problem (VRP) network analysis layer and sets its analysis properties. A VRP analysis layer is useful for optimizing a set of routes using a fleet of vehicles. The layer can be created using a local network dataset or a service hosted online or in a portal.

Usage

  • This tool is typically used as the first step in a network analysis workflow. Once the layer is created, you can add inputs to it using the Add Locations tool and solve the analysis using the Solve tool.

    Learn more about the network analysis layer workflow

  • The analysis network used for a vehicle routing problem analysis must have at least one travel mode whose impedance attribute has units of time.

  • When ArcGIS Online or an ArcGIS Enterprise portal whose routing services are configured using ArcGIS Online is used as the input network data source, solving the analysis will consume credits and will be subject to certain limits, such as the number of allowed inputs.

    Learn more about credit consumption and analysis limits in network analysis

  • By default, the new analysis layer's data will be created in a new, automatically-named feature dataset in the Current Workspace geoprocessing environment, which is usually the project geodatabase. Table-based data will be created at the root level of the same geodatabase because tables cannot be stored in a feature dataset. You can override this behavior using the Analysis Geodatabase and Analysis Feature Dataset Name parameters.

  • Although this tool can be used in a Python script, the recommended best practice for performing network analysis in Python is to use the solver classes in the arcpy.nax module instead.

    Learn more about performing network analysis in Python.

Parameters

Label Explanation Data type

Network Data Source

The network dataset or service on which the network analysis will be performed.

The parameter can be specified using the following:

  • The catalog path to a network dataset.

  • A network dataset layer

  • The URL for ArcGIS Online or an ArcGIS Enterprise portal configured with standard routing services

To use a portal URL, you must be signed in to the portal with an account that has routing privileges.

Learn more about network analysis using routing services

When using ArcGIS Online or an ArcGIS Enterprise portal whose routing services are configured using ArcGIS Online as the input network, solving the analysis will consume credits and will be subject to certain limits, such as the number of allowed inputs.

Learn more about credit consumption and analysis limits in network analysis

The network must have at least one travel mode whose impedance attribute has units of time.

Network Dataset Layer; String

Layer Name

(Optional)

The name of the VRP network analysis layer to create.

String

Travel Mode

(Optional)

The name of the travel mode to use in the analysis. The travel mode represents a collection of network settings, such as travel restrictions and U-turn policies, that determine how a pedestrian, car, truck, or other medium of transportation moves through the network. Travel modes are defined on your network data source. An arcpy.na.TravelMode object and a string containing the valid JSON representation of a travel mode can also be used as input to the parameter.

VRP only solves with a time-based impedance, so only time-based impedance travel modes are available for selection.

String

Time Field Units

(Optional)

Specifies the time units to be used by the temporal fields of the analysis layer's sublayers and tables (network analysis classes). This value does not need to match the units of the time cost attribute.

Learn more about cost attributes

  • MinutesThe time units will be minutes. This is the default.

  • SecondsThe time units will be seconds.

  • HoursThe time units will be hours.

  • DaysThe time units will be days.

String

Distance Field Units

(Optional)

Specifies the distance units to be used by the distance fields of the analysis layer's sublayers and tables (network analysis classes). This value does not need to match the units of the optional distance cost attribute.

Learn more about cost attributes

  • MilesThe distance units will be miles. This is the default.

  • KilometersThe distance units will be kilometers.

  • FeetThe distance units will be feet.

  • YardsThe distance units will be yards.

  • MetersThe distance units will be meters.

  • InchesThe distance units will be inches.

  • CentimetersThe distance units will be centimeters.

  • MillimetersThe distance units will be millimeters.

  • DecimetersThe distance units will be decimeters.

  • Nautical MilesThe distance units will be nautical miles.

String

Default Date

(Optional)

The implied date for time field values that don't have a date specified with the time. If a time field for an order object, such as TimeWindowStart, has a time-only value, the date is assumed to be the default date. The default date has no effect on time field values that already have a date.

Configure the analysis to use one of the following special dates to model a day of the week or the current date instead of a specific, static date:

  • Today—12/30/1899

  • Sunday—12/31/1899

  • Monday—1/1/1900

  • Tuesday—1/2/1900

  • Wednesday—1/3/1900

  • Thursday—1/4/1900

  • Friday—1/5/1900

  • Saturday—1/6/1900

Learn more about how dates and times are used and interpreted in a network analysis

Date

Time Zone for Time Fields

(Optional)

Specifies the time zone to be used for the input date-time fields supported by the tool.

Specifying the date-time values in UTC is useful if you do not know the time zone in which the orders or depots are located or when you have orders and depots in multiple time zones and you want all the date-time values to start simultaneously. The UTC option is applicable only when your network dataset defines a time zone attribute. Otherwise, all the date-time values are treated as the time zone corresponding to that location.

  • Local time at locationsThe date-time values associated with the orders or depots will be in the time zone in which the orders and depots are located. For routes, the date-time values are based on the time zone in which the starting depot for the route is located. If a route does not have a starting depot, all orders and depots across all the routes must be in a single time zone. For breaks, the date-time values are based on the time zone of the routes. This is the default.

  • UTCThe date-time values associated with the orders or depots will be in coordinated universal time (UTC) and are not based on the time zone in which the orders or depots are located.

String

Output Route Shape

(Optional)

Specifies the shape type that will be used for the route features that are output by the analysis.

Regardless of the output shape type specified, the best route is always determined by the network impedance, not Euclidean distance. This means that only the route shapes are different, not the underlying traversal of the network.

  • Along networkThe output routes will have the exact shape of the underlying network sources. The output includes route measurements for linear referencing. The measurements increase from the first stop and record the cumulative impedance to reach a given position.

  • No linesNo shape will be generated for the output routes.

  • Straight linesThe output route shape will be a single straight line between the stops.This option is not available if the selected network data source is a service.

String

Time Window Violation Importance

(Optional)

Specifies the importance of honoring time windows without causing violations. A time window violation occurs when a route arrives at an order, depot, or break after a time window has closed. The violation is the interval between the end of the time window and the arrival time of a route.

  • HighThe solver searches for a solution that minimizes time window violations at the expense of increasing the overall travel time. Choose this setting if arriving on time at orders is more important than minimizing the overall solution cost. This may be the case if you are meeting customers at your orders and you don't want to inconvenience them with late arrivals (another option is to use rigid time windows that cannot be violated).Given other constraints of a vehicle routing problem, it may be impossible to visit all the orders within their time windows. In this case, even a High setting may produce violations.

  • MediumThe solver searches for a balance between meeting time windows and reducing the overall solution cost. This is the default.

  • LowThe solver searches for a solution that minimizes overall travel time, regardless of time windows. Choose this setting if respecting time windows is less important than reducing the overall solution cost. You may want to use this setting if you have a growing backlog of service requests. For the purpose of servicing more orders in a day and reducing the backlog, you can choose this setting even though customers may be inconvenienced with your fleet's late arrivals.

String

Excess Transit Time Importance

(Optional)

Specifies the importance of reducing excess transit time. Excess transit time is the amount of time exceeding the time required to travel directly between paired orders. The excess time results from breaks or travel to other orders or depots between visits to the paired orders. This parameter is only relevant if you're using Order Pairs.

Learn more about Order Pairs

  • HighThe solver searches for a solution with less excess transit time between paired orders at the expense of increasing the overall travel costs. Use this setting if you are transporting people between paired orders and you want to shorten their ride time. This is characteristic of taxi services.

  • MediumThe solver searches for a balance between reducing excess transit time and reducing the overall solution cost. This is the default.

  • LowThe solver searches for a solution that minimizes overall solution cost, regardless of excess transit time. This setting is commonly used with courier services. Since couriers transport packages as opposed to people, ride time is not as important. Using this setting allows couriers to service paired orders in the proper sequence and minimize the overall solution cost.

String

Generate Directions on Solve

(Optional)

Specifies whether directions will be generated when running the analysis.

For an analysis in which generating turn-by-turn directions is not needed, turn directions generation off to reduce the time it takes to solve the analysis.

  • CheckedTurn-by-turn directions will be generated on solve. This is the default.

  • UncheckedTurn-by-turn directions will not be generated on solve.

Boolean

Spatial Clustering

(Optional)

Specifies whether spatial clustering will be used.

  • CheckedThe orders assigned to an individual route will be spatially clustered. Clustering orders tends to keep routes in smaller areas and reduce how often route lines intersect one another; however, clustering can increase overall travel times. This is the default.

  • UncheckedThe solver will not prioritize spatially clustering orders and the route lines may intersect. Use this option if route zones are specified.

Boolean

Ignore Invalid Locations at Solve Time

(Optional)

Specifies whether invalid input locations will be ignored.

  • CheckedInvalid input locations will be ignored so that the analysis will succeed using only valid locations.

  • UncheckedInvalid locations will not be ignored and will cause the analysis to fail. This is the default.

Boolean

Analysis Geodatabase

(Optional)

The file geodatabase workspace where the new network analysis layer's sublayer data will be stored. When this parameter is not specified, the sublayer data will be created in the Current Workspace geoprocessing environment, which is usually the project geodatabase.

Learn more about the analysis data source of a network analysis layer

Workspace

Analysis Feature Dataset Name

(Optional)

The name to use for the new feature dataset that the tool will create in the analysis geodatabase to store the network analysis layer's sublayer data. When not specified, the feature dataset will be created with a random unique name.

Learn more about the analysis data source of a network analysis layer

String

Derived output

Label Explanation Data type

Network Analyst Layer

The new network analysis layer.

Network Analyst Layer

Environments

Current Workspace

Licensing information

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