ArcGIS Desktop

  • ArcGIS Pro
  • ArcMap

  • My Profile
  • Справка
  • Sign Out
ArcGIS Desktop

ArcGIS Online

Картографическая платформа вашей организации

ArcGIS Desktop

Полноценная профессиональная ГИС

ArcGIS Enterprise

ГИС предприятия

ArcGIS Developers

Инструменты для встраивания приложений с местоположениями

ArcGIS Solutions

Бесплатные шаблоны карт и приложений для отрасли

ArcGIS Marketplace

Получение приложения и данных для вашей организации.

  • Документация
  • Поддержка
Esri
  • Войти
user
  • Мой профиль
  • Выход

ArcMap

  • На главную
  • Начало работы
  • Карта
  • Анализ
  • Управление данными
  • Инструменты
  • Дополнительные модули

Calculate Areas

  • Сводка
  • Иллюстрация
  • Использование
  • Синтаксис
  • Пример кода
  • Параметры среды
  • Информация о лицензиях

Сводка

Calculates area values for each feature in a polygon feature class.

Прежние версии:

Because there are easier and more efficient ways to get the area of features, the Calculate Areas tool has been deprecated. Use the Calculate Field tool or the Geometry Calculator instead of the Calculate Areas tool in your workflows and custom script or models tools. If you are using feature classes in a geodatabase, the shape_area attribute field is maintained for you automatically.

Иллюстрация

Calculate Areas illustration

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

  • The F_AREA field created in the Output Feature Class will be populated with values for the area of each polygon feature in square units of the Output Coordinate System.

  • There are alternative methods for creating an Area field for polygon features including: Calculate Field and the Geometry Calculator.

  • The Output Feature Class is a copy of the Input Feature Class with the additional (or updated) F_AREA field containing polygon areas.

  • Внимание:

    The F_AREA field is created in the Output Feature Class to store calculated Area values. If a field of this name already exists in the Input Feature Class, it will be overwritten in the Output Feature Class.

    Внимание:

    При использовании шейп-файлов, помните, что в них нельзя хранить нулевые (null) значения. Инструменты или другие процедуры, создающие шейп-файлы из прочих входных данных, могут хранить значения NULL в виде 0 или оперировать ими как нулем. В некоторых случаях нули в шейп-файлах хранятся как очень маленькие отрицательные числа. Это может привести к неожиданным результатам. Дополнительные сведения см. в разделе Рекомендации по геообработке выходных данных шейп-файла.

Синтаксис

arcpy.stats.CalculateAreas(Input_Feature_Class, Output_Feature_Class)
ПараметрОбъяснениеТип данных
Input_Feature_Class

The input polygon feature class.

Feature Layer
Output_Feature_Class

The output feature class. This feature class is a copy of the input feature class with field F_AREA added (or updated). The F_AREA field contains the polygon area.

Feature Class

Пример кода

CalculateAreas Example (Python Window)

The following Python Window script demonstrates how to use the CalculateAreas tool.

import arcpy
arcpy.env.workspace = "c:/data"
arcpy.CalculateAreas_stats("tracts.shp", "tracts_with_area_field.shp")
CalculateAreas Example (stand-alone Python script)

The following stand-alone Python script demonstrates how to use the CalculateAreas tool.

# Calculate AREA values
 
# Import system modules
import arcpy
 
# Local variables...
workspace = "C:/data"
input = "tracts.shp"
calculate_output = "tracts_with_area_field.shp"
 
try:
    # Set the current workspace (to avoid having to specify the full path to the feature classes each time)
    arcpy.env.workspace = workspace
 
    # Process: Calculate Areas...
    arcpy.CalculateAreas_stats(input, calculate_output)
 
except:
    # If an error occurred when running the tool, print out the error message.
    print arcpy.GetMessages()

Параметры среды

  • Выходная система координат
    Примечание:

    Feature geometry is projected to the Output Coordinate System prior to analysis.

  • Текущая рабочая область
  • Временная рабочая область
  • Полноценные имена полей
  • Выходные данные имеют M-значения
  • Выходные данные имеют Z-значения
  • Выходное значение Z по умолчанию

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

  • Basic: Да
  • Standard: Да
  • Advanced: Да

ArcGIS Desktop

  • На главную
  • Документация
  • Поддержка

ArcGIS

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

Об Esri

  • О нас
  • Карьера
  • Блог Esri
  • Конференция пользователей
  • Саммит разработчиков
Esri
Расскажите нам, что вы думаете.
Copyright © 2021 Esri. | Конфиденциальность | Правовая информация