本文简要介绍 python 语言中 arcgis.geoanalytics.manage_data.dissolve_boundaries
的用法。
用法:
arcgis.geoanalytics.manage_data.dissolve_boundaries(input_layer, dissolve_fields=None, summary_fields=None, multipart=False, output_name=None, gis=None, context=None, future=False)
返回:
dissolve_boundaries
任务查找相交或具有相同字段值的多边形,并将它们合并在一起以形成单个多边形。例子:
A city council wants to control liquor sales by refusing new licenses to stores within 1,000 feet of schools, libraries, and parks. After creating a 1,000-foot buffer around the schools, libraries, and parks, the buffered layers can be joined together and the boundaries can be dissolved to create a single layer of restricted areas.
注意:
仅在 ArcGIS Enterprise 10.7 及更高版本中可用。
Parameter
Description
input_layer
必需的层。包含将被融合的面要素的图层。请参阅特征输入。
dissolve_fields
可选字符串。您想要溶解的每个字段的逗号分隔字符串列表。
input_layer
中的一个或多个字段确定如何根据字段值合并多边形。如果不指定字段,相交的多边形默认会分解为一个多边形。
如果指定字段,则每个指定字段共享相同值的多边形将被分解为一个多边形。
summary_fields
可选的字典列表。您要计算的字段名称和统计汇总类型的列表。请注意,始终返回计数。默认情况下,返回所有统计信息。
用法:
[{"statisticType" : "<stat>", "onStatisticField" : "<field name>"}]
onStatisticField
is the name of the field in the input point layer to calculate the statistic.statisticType
is one of the following for numeric fields:Count
- Totals the number of values of all the points in each polygon.Sum
- Adds the total value of all the points in each polygon.Mean
- Calculates the average of all the points in each polygon.Min
- Finds the smallest value of all the points in each polygon.Max
- Finds the largest value of all the points in each polygon.Range
- Finds the difference between the Min and Max values.Stddev
- Finds the standard deviation of all the points in each polygon.Var
- Finds the variance of all the points in each polygon.
statisticType
is one of the following for string fields:Count
- Totals the number of strings for all the points in each polygon.Any
- Returns a sample string of a point in each polygon.
# Example >>> summary_fields = [{"statisticType" : "Sum", "onStatisticField" : "quadrat_area_km2"}, {"statisticType" : "Mean", "onStatisticField" : "soil_depth_cm"}, {"statisticType" : "Any", "onStatisticField" : "quadrat_desc"}]
multipart
可选布尔值。如果是
True
,则输出服务可以包含多部分函数。如果False
,输出服务将仅包含 single-part 特征,并且将为每个部分创建单独的特征。默认值为
False
。output_name
可选字符串。该任务将创建结果的要素服务。您定义服务的名称。
gis
可选
GIS
,将对其进行分析。context
可选字典。 context 参数包含影响任务执行的其他设置。对于此任务,有五个设置:
extent
- A bounding box that defines the analysis area. Only those features that intersect the bounding box will be analyzed.processSR
- The features will be projected into this coordinate system for analysis.outSR
- The features will be projected into this coordinate system after the analysis to be saved. The output spatial reference for the spatiotemporal big data store is always WGS84.dataStore
- Results will be saved to the specified data store. For ArcGIS Enterprise, the default is the spatiotemporal big data store.defaultAggregationStyles
- If set to true, results will have square, hexagon, and triangle aggregation styles enabled on results map services.
future
可选布尔值。如果是
True
,将返回一个 future 对象,并且进程不会等待任务完成。默认为False
,表示等待结果。例子:
# Usage Example: This example dissolves boundaries of soil areas in Nebraska if they have # the same solubility. For dissolved features, it calculates the sum of the quadrat area, # the mean soil depth, and an example of the quadrat description. arcgis.env.out_spatial_reference = 3310 arcgis.env.output_datastore= "relational" arcgis.env.defaultAggregations= True summary_fields = [{"statisticType" : "Sum", "onStatisticField" : "quadrat_area_km2"}, {"statisticType" : "Mean", "onStatisticField" : "soil_depth_cm"}, {"statisticType" : "Any", "onStatisticField" : "quadrat_desc"}] dissolve_result = dissolve_boundaries(input_layer=study_area_lyr, dissolve_fields="soil_suitability", summary_fields=summary_fields, multipart=True, output_name="Soil_Suitability_dissolved")
相关用法
- Python ArcGIS dissolve_boundaries用法及代码示例
- Python ArcGIS divide用法及代码示例
- Python ArcGIS dimensional_moving_statistics用法及代码示例
- Python ArcGIS describe_dataset用法及代码示例
- Python ArcGIS delete_image用法及代码示例
- Python ArcGIS detect_incidents用法及代码示例
- Python ArcGIS delete_image_collection用法及代码示例
- Python arcgis.learn.detect_objects用法及代码示例
- Python ArcGIS detect_change_using_change_analysis_raster用法及代码示例
- Python ArcGIS define_nodata用法及代码示例
- Python ArcGIS densify用法及代码示例
- Python ArcGIS derive_new_locations用法及代码示例
- Python ArcGIS power用法及代码示例
- Python ArcGIS APIKeyManager.get用法及代码示例
- Python ArcGIS KnowledgeGraph.named_object_type_delete用法及代码示例
- Python ArcGIS ContentManager.unshare_items用法及代码示例
- Python ArcGIS ImageryLayer.thumbnail用法及代码示例
- Python ArcGIS FormFieldElement用法及代码示例
- Python ArcGIS Geometry.true_centroid用法及代码示例
- Python ArcGIS Site.delete用法及代码示例
- Python ArcGIS GeoAccessor.bbox用法及代码示例
- Python arcgis.apps.hub.Initiative.update用法及代码示例
- Python ArcGIS generate_service_areas用法及代码示例
- Python ArcGIS build_overview用法及代码示例
- Python ArcGIS RunInterval用法及代码示例
注:本文由纯净天空筛选整理自arcgis.com大神的英文原创作品 arcgis.geoanalytics.manage_data.dissolve_boundaries。非经特殊声明,原始代码版权归原作者所有,本译文未经允许或授权,请勿转载或复制。