Set Territory Distance Parameters (Territory Design)

Доступно с лицензией Business Analyst.

Сводка

Defines the type of distance calculation or distance constraints to use when creating territories.

Использование

  • Maximum Territory Radius specifies the maximum size of the territory. Adjacent territories can be smaller than the radius specified if the boundaries between territories overlap. Territories will expand until the radius value is reached.

    Maximum Territory Radius

  • Territory Buffer Distance specifies the buffer size around each territory that cannot be encroached. Territories will be constrained by the adjacent territory buffer.

    Territory Buffer Distance

  • When setting Minimum Distance Between Centers, the distance between centers can be greater than the minimum distance.

    Minimum Distance Between Centers

  • If a network distance is specified, a Territory Network Index (TNI) will be created during the Solve tool execution.

  • If Network Parameters are set, a summary of network settings will be written, as messages at the bottom of the Geoprocessing pane, during the execution of the Solve tool.

  • Network Data Source must be set to a local network dataset. Online network solvers are not supported.

Синтаксис

arcpy.td.SetTerritoryDistanceParameters(in_territory_solution, level, {distance_type}, {units}, {max_radius}, {buffer_distance}, {min_distance}, {network_datasource}, {build_index}, {travel_direction}, {time_of_day}, {time_zone}, {search_tolerance})
ParameterОбъяснениеТип данных
in_territory_solution

The Territory Design solution layer that will be used in the analysis.

Group Layer; Feature Dataset; String
level

The level to which the distance parameters will be applied.

String
distance_type
(Дополнительный)

Specifies how distance is calculated based on method of travel.

  • STRAIGHT_LINEStraight-line, or Euclidean distance, is used as the distance measure. This is the default.
  • Additional distance types (travel modes—for example, Driving Time, Driving Distance) will be dependent on the available network dataset.
String
units
(Дополнительный)

Specifies the type of measuring units that will be used.

  • METERSThe distance unit is meters.
  • MILESThe distance unit is miles.
  • NAUTICAL_MILESThe distance unit is nautical miles.
  • KILOMETERSThe distance unit is kilometers.
  • YARDSThe distance unit is yards.
  • FEETThe distance unit is feet.
  • INCHESThe distance unit is inches.
  • DECIMETERSThe distance unit is decimeters.
  • CENTIMETERSThe distance unit is centimeters.
  • MILLIMETERSThe distance unit is millimeters.
  • DECIMAL_DEGREESThe distance unit is decimal degrees.
  • MINUTESThe time unit is minutes.
  • HOURSThe time unit is hours.
  • DAYSThe time unit is days.
  • SECONDSThe time unit is seconds.
String
max_radius
(Дополнительный)

The maximum radius of the territory.

Double
buffer_distance
(Дополнительный)

The radius of the territory buffer.

Double
min_distance
(Дополнительный)

The minimum distance between territory centers.

Double
network_datasource
(Дополнительный)

The network dataset on which the network distance calculation will be performed.

Network Dataset Layer
build_index
(Дополнительный)

Specifies whether or not to build an index. A network index will improve performance when solving the Territory Solution.

  • BUILD_INDEXCreate a network index. This is the default.
  • DO_NOT_BUILD_INDEXDo not create a network index.
Boolean
travel_direction
(Дополнительный)

Specifies the direction of travel between stores and customers.

  • TOWARD_STORESDirection of travel is from customers to stores. This is the default.
  • AWAY_FROM_STORESDirection of travel is from stores to customers.
String
time_of_day
(Дополнительный)

Specifies the time and date when calculating distance.

Date
time_zone
(Дополнительный)

Specifies the time zone of the Time of Day parameter.

  • TIME_ZONE_AT_LOCATIONThe time zone in which the territories are located. This is the default.
  • UTC Refers to coordinated universal time (UTC).
String
search_tolerance
(Дополнительный)

The search tolerance for locating territories on the network. Territories that are outside the search tolerance are left unlocated.

The parameter requires a distance value and units for the tolerance. The default value is 5000 Meters.

Linear Unit

Производные выходные данные

NameОбъяснениеТип данных
out_territory_solution

The updated territory solution.

Group Layer

Пример кода

SetTerritoryDistanceParameters example (Python window)

The following Python window script demonstrates how to use the SetTerritoryDistanceParameters tool.

import arcpy
arcpy.td.SetTerritoryDistanceParameters("TerritorySolution", "Territories[1]", "STRAIGHT_LINE", "MILES", 5, 1, 3, "\Data\Streets Data\NorthAmerica.gdb\Routing\Routing_ND", "BUILD_INDEX", None, "5:30:00 PM", "TIME_ZONE_AT_LOCATION", "5000 Meters")

Информация о лицензиях

  • Basic: Требуется Business Analyst
  • Standard: Требуется Business Analyst
  • Advanced: Требуется Business Analyst

Связанные разделы