ArcGIS Desktop

  • ArcGIS Pro
  • ArcMap

  • My Profile
  • 帮助
  • Sign Out
ArcGIS Desktop

ArcGIS Online

专为贵组织打造的制图平台

ArcGIS Desktop

全面的专业性 GIS

ArcGIS Enterprise

面向企业的 GIS

ArcGIS Developers

用于构建位置感知应用程序的工具

ArcGIS Solutions

适用于行业的免费模板地图和应用程序

ArcGIS Marketplace

获取适用于组织的应用程序和数据

  • 文档
  • 支持
Esri
  • 登录
user
  • 我的个人资料
  • 登出

ArcMap

  • 主页
  • 入门
  • 地图
  • 分析
  • 管理数据
  • 工具
  • 扩展模块

Delete Dangles

获得 Production Mapping 许可后可用。

  • 描述
  • 插图
  • 使用方法
  • 语法
  • 代码示例
  • 环境
  • 许可信息

描述

Removes lines that are shorter than the specified length and do not connect to other features on both ends.

插图

Delete Dangles example

使用方法

    警告:

    此工具会修改输入数据。有关详细信息以及避免数据被意外更改的策略,请参阅不创建输出数据集的工具。

  • A warning is raised if the input features are not in a projected coordinate system. This tool relies on linear distance units, which will create unexpected results in an unprojected coordinate system. It is strongly suggested that you run this tool on data in a projected coordinate system to ensure valid results. An error is raised and the tool will not process if the coordinate system is missing or unknown.

  • Input line features that are below the minimum length and do not touch another line at both end points are deleted.

  • If a maximum angle is entered, the dangles that are kept will be measured in length with a consecutive line. If the combined length is below the defined minimum length, both lines will be removed.

  • Features connected to any feature class listed in the Compare Features (Compare_Features for Python) parameter are not considered dangles.

  • If this tool is run in an edit session in ArcMap, you can stop the edit session without saving changes to restore features that have been deleted.

语法

arcpy.production.DeleteDangles(Input_Line_Features, Minimum_Length, {Compare_Features}, Recursive, {Maximum_Angle})
参数说明数据类型
Input_Line_Features

The features that will be checked for dangles.

Feature Layer
Minimum_Length

The minimum length for input lines. Features shorter than this are deleted.

Linear unit
Compare_Features
[Compare_Features,...]
(可选)

Additional features the input line features can be compared to when determining whether the feature is a dangle.

Feature Layer
Recursive

Indicates the method used to delete dangles on the line features.

  • NON_RECURSIVE —All the dangles on lines are deleted. The remaining lines are not analyzed to see if they are dangles. This is the default.
  • RECURSIVE —The dangles are deleted from the lines and the remaining lines are analyzed to see if they are considered dangles. If they do not meet the Minimum_Length value, they are considered dangles and deleted.
Boolean
Maximum_Angle
(可选)

Any line below the minimum length that is within the defined angle of a consecutive line segment will be kept.

Double

代码示例

DeleteDangles example (stand-alone script)

The following stand-alone sample script demonstrates how to use DeleteDangles.

# Name: DeleteDangles_Example.py
# Description: Uses Production Mapping tool Delete Dangles to remove
#   unconnected lines less than a certain length unless within a defined
#   angle.
# Author: Esri
# Date: December 2015

# Import arcpy module
import arcpy

# Check out Production Mapping license
arcpy.CheckOutExtension("Foundation")

# set environment
arcpy.env.workspace="c:/data/LocalGovernment.gdb"

# Define variables
inFeatures="ReferenceData/RoadCenterline"
inCompareFeatures="ReferenceData/Hospital"
inFeaturesLyr="RoadL_Lyr"
inCompareFeaturesLyr="Hospital_Lyr"
recursion = 'NON_RECURSIVE'
minLength="10 Feet"
maxAngle="45"

# Create an input feature layer for DeleteDangles
arcpy.MakeFeatureLayer_management(inFeatures,inFeaturesLyr)
arcpy.MakeFeatureLayer_management(inCompareFeatures, inCompareFeaturesLyr)

# Execute the tool
arcpy.DeleteDangles_production(inFeaturesLyr,minLength,inCompareFeaturesLyr,recursion,maxAngle)

环境

  • 当前工作空间
  • 临时工作空间

许可信息

  • Basic: 否
  • Standard: 否
  • Advanced: 需要 Production Mapping

相关主题

  • An overview of the Generalization toolset
  • Increase Line Length

ArcGIS Desktop

  • 主页
  • 文档
  • 支持

ArcGIS

  • ArcGIS Online
  • ArcGIS Desktop
  • ArcGIS Enterprise
  • ArcGIS
  • ArcGIS Developer
  • ArcGIS Solutions
  • ArcGIS Marketplace

关于 Esri

  • 关于我们
  • 招贤纳士
  • Esri 博客
  • 用户大会
  • 开发者峰会
Esri
分享您的想法。
Copyright © 2021 Esri. | 隐私政策 | 法律声明