Distance Decay Report (Business Analyst)

汇总

Calculates market penetration for a number of ring or drive-time polygons around your stores.

用法

语法

DistanceDecayReport_ba (InputFeatureLayer, IDField, All_Or_Single_Or_Selected, RingsType, RingsCollection, {MeasureUnits}, CustomerLayer, MarketPenetrationTMCType, MarketPenetrationTMCField, InputGeographyLevel, MarketPenetrationTMCSummarization, ReportTitle, MarketPenetrationReportDirectory, {ByID_Or_ByName}, {Single_Site}, {Donut}, {RemoveOverlap}, {BorderShape}, IN_MP_STORE_ID, {UseSelectedCustomers}, {CustomerWeightField}, {IN_CL_STORE_ID}, {ReportFormats;ReportFormats...}, {BarrierFeatureClasses})
参数说明数据类型
InputFeatureLayer

The input feature class containing center points for the report. In most cases, this will be a Business Analyst store layer.

Feature Layer
IDField

Unique ID field in the store layer.

Field
All_Or_Single_Or_Selected

Creates trade areas for points in the input feature layer.

  • ALLTrade areas are created for all points.
  • SINGLETrade areas are created for a single point.
  • SELECTEDTrade areas are created for selected points in ArcMap.
String
RingsType

Determines how the generated trade areas will be derived.

  • Simple Ring AreasGenerates one or more static rings based on the center point(s) of the store layer.
  • Drive Time AreasGenerates one or more drive-time polygons based on the center point(s) of the store layer.
String
RingsCollection
[RingsCollection,...]

The distances, in ascending size, used to create trade areas around the input features.

Double
MeasureUnits
(可选)

The units used with the distance values. By default, the units defined in the Business Analyst preferences will be selected.

  • Decimal Degrees
  • Feet
  • Kilometers
  • Meters
  • MilesThis is the default.
  • Nautical Miles
  • Yards
String
CustomerLayer

The input feature class containing the points for the customer distribution. In most cases, this will be a Business Analyst customer layer.

Feature Layer
MarketPenetrationTMCType

Determines the location where the market count calculation will be derived.

  • In the layer attribute tableCalculates the market penetration based on nonstandard geography.
  • Calculate using Geography LevelCalculates the market penetration based on a standard geography layer.
  • Calculate Using Business Analyst Online DataCalculates the market penetration based on online Business Analyst data.
String
MarketPenetrationTMCField

The field that contains the base total market counts from the market penetration layer used in calculating the market penetration.

String
InputGeographyLevel

Selects the geography level that will contain the total market counts.

Feature Layer
MarketPenetrationTMCSummarization

The attribute field that contains the variable used for the total market count selected from the geography level.

String
ReportTitle

The title for the report.

String
MarketPenetrationReportDirectory

The output directory where the report will be saved.

Folder
ByID_Or_ByName
(可选)

Field used to select a single point.

  • IDSelects a single point using the store ID field.
  • NameSelects a single point using the store name field.
String
Single_Site
(可选)

ID or name of store to be used as the single point.

String
Donut
(可选)

Creates nonoverlapping concentric rings or donut bands.

  • TrueConcentric rings are created. This is the default option.
  • FalseCreates output polygons that are donut rings. For example, if three radii (1, 2, and 3 miles) are entered, three output bands would be created with 0–1-, 1–3-, and 3–5-mile rings.
Boolean
RemoveOverlap
(可选)

Removes the overlap using the Thiessen approach by drawing lines of equal distance between two adjacent polygons.

  • TrueRemoves the overlap between trade areas.
  • FalseDoes not remove the overlap between trade areas. This is the default.
Boolean
BorderShape
(可选)

Creates a detailed border ignoring areas that cannot be reached when driven.

  • TrueGenerates detailed borders around trade areas.
  • FalseDoes not generate detailed borders around trade areas. This is the default.
Boolean
IN_MP_STORE_ID

Unique ID field based on the layer for calculating market penetration. This store ID is a field in the Market Penetration layer.

Field
UseSelectedCustomers
(可选)

Uses selected features to generate the Distance Decay report.

  • TrueGenerates the Distance Decay report on selected features.
  • FalseGenerates the Distance Decay report on all features. This is the default
Boolean
CustomerWeightField
(可选)

Defines the attribute of the customer layer that will be used to weight the trade areas.

Field
IN_CL_STORE_ID
(可选)

The store ID field that will be used to identify which customers are associated with each store. This Store ID is a field in the Customer Layer.

Field
ReportFormats;ReportFormats...
[ReportFormats;ReportFormats...,...]
(可选)

Select the desired report output format.

  • Simple XML
  • PDF
  • HTML
  • CSV
  • ZIP
  • XLSV
  • Stripped XLSX
String
BarrierFeatureClasses
[BarrierFeatureClasses,...]
(可选)

Point, line, or polygon barriers to use when drive time or drive distance is used to calculate distances.

Feature Layer

代码示例

DistanceDecayReport Example (Stand-alone Script)
# Name: DistanceDecayReport.py
# Description: Calculates the market penetration in San Francisco based on a series of simple ring trade areas comparing the sales in each ring to the total population.
# Author: ESRI

# Import system modules
import arcview
import arcpy

arcpy.ImportToolbox("C:\Program Files\ArcGIS\Desktop10.0\ArcToolbox\Toolboxes\Business Analyst Tools.tbx")
 
try:
  # Acquire extension license 
  arcpy.CheckOutExtension("Business")
     
  # Define input and output parameters for the Distance Decay Report tool
  Store = "C:/temp/sf_stores.shp"
  Cust = "C:/temp/sf_cust.shp"
  Id = "STORE_ID"
  MarketPen = "C:/Temp/Decay/MpLayer.shp"
  Method = "Calculate using Geography Level"
  Weight = "SALES"
  Data = "C:/Program Files/ArcGIS/Desktop10.0/Business Analyst/Data/BDS/esri_bg.bds"
  Var = "TOTPOP_CY"
  Output = "C:/temp/DecayReport2"
 
  # Create Distance Decay reports
  arcpy.DistanceDecayReport_ba(Store, Id, "ALL", 'Simple Ring Areas', "1;2;3", "Miles", Cust, Method, Weight, Data, Var, "Ring Penetration", Output, "#", "#", "false", "false","false", "#", "false", "#", "#",sMarketPen)
 
  # Release extension license 
  arcpy.CheckInExtension("Business")
 
except:
  print arcpy.GetMessages(2)

环境

此工具不使用任何地理处理环境

相关主题

许可信息

ArcView: 需要 Business Analyst
ArcEditor: 需要 Business Analyst
ArcInfo: 需要 Business Analyst

10/4/2010