Summarize Within

Title  Summarize Within

Summary

Overlays a polygon layer with another layer to summarize the number of points, length of the lines, or area of the polygons within each polygon, and calculate attribute field statistics about the features within the polygons.


Usage

Syntax

ParameterExplanation
in_sum_features

The point, line, or polygon features that will be summarized for each polygon in the input polygons.

out_feature_class

The output polygon feature class containing the same geometries and attributes as the input polygons. The feature class will include additional attributes for the number of points, length of lines, and area of polygons inside each input polygon and statistics about those features.

shape_unit (Optional)

Specifies the unit that will be used when calculating shape summary attributes. If the input summary features are points, no shape unit is necessary, since only the count of points in each input polygon is added.If the input summary features are lines, specify a linear unit. If the input summary features are polygons, specify an areal unit.Meters—The unit will be meters.Kilometers—The unit will be kilometers.Feet—The unit will be feet.Yards—The unit will be yards.Miles—The unit will be miles.Acres—The unit will be acres.Hectares—The unit will be hectares.Square meters—The unit will be square meters.Square kilometers—The unit will be square kilometers.Square feet—The unit will be square feet.Square yards—The unit will be square yards.Square miles—The unit will be square miles.

group_field (Optional)

An attribute field from the input summary features that will be used for grouping. Features that have the same group field value will be combined and summarized with other features with the same group field value.When a group field is provided, the Output Grouped Table parameter value is required.

add_min_maj (Optional)

Specifies whether minority and majority fields will be added to the output. This parameter allows you to determine which group field value is the minority (least dominant) and the majority (most dominant) within each input polygon.This parameter is active if you provided a Group Field parameter value.Unchecked—Minority and majority fields will not be added to the output. This is the default.Checked—Minority and majority fields will be added to the output.

out_group_table (Optional)

An output table that includes summary fields for each group of summary features for each input polygon.The table will have the following attribute fields:Join_ID—An ID corresponding to an ID field added to the output feature classThe group fieldA shape summary fieldOne field for each summary fieldA percentage fieldThis parameter is required when the Group Field parameter value is provided.

Code Samples

Tags

count, inside, overlap, overlay, polygon, sum, summary

Credits

Use limitations