How Zonal Geometry works

The Zonal Geometry tool returns information about the geometry, or shape, of each zone in a raster. A zone does not need to be a single, connected entity; it can be composed of a number of disconnected areas (regions).

With the Zonal Geometry tool, there are four types of geometry that can be calculated, as determined by the Geometry type parameter:

The Zonal Geometry as Table tool calculates all of the geometry measures but returns the result as a table instead of an output raster.

The output results for Area, Perimeter, and Thickness geometry types are presented in map units. For geometry type Centroid, the output values for the major axis and minor axis are also in map units.

Where the zone dataset is a feature dataset, it will be converted internally to a raster at the output cell size resolution.

Changing the cell size in the analysis environment can influence the output values due to resampling and accumulated rounding errors.

Area

For each zone in the input raster, zonal area determines the total area of each zone and assigns it to each cell in the zone on the output raster. The area is calculated by the number of cells that comprise the zone multiplied by the current cell size.

The area for all regions will be calculated and summed together, so that only one value will be assigned to the zone in the output.

The area is measured in square map units.

Example

The following illustration shows the output of the Zonal Geometry tool on the input raster with Geometry type set to Area and a cellsize of 1:

Area Zonal Geometry illustration
OutRas = ZonalGeometry(InRas1,"VALUE","AREA")

Perimeter

Zonal perimeter determines the perimeter of each zone on the input raster and assigns it to each cell in the zone on an output raster. The perimeter of a zone is calculated by summing the lengths of the cells that comprise the boundaries of the zone. Both external boundaries and internal boundaries (islands) are taken into account.

If the zone has multiple regions, the perimeters of each will be summed together so that only one value is assigned to the zone in the output.

The perimeter value is measured in linear map units.

Example

The following illustration shows the output of the Zonal Geometry tool on the input raster with Geometry type set to Perimeter:

Perimeter Zonal Geometry illustration
OutRas = ZonalGeometry(InRas1,"VALUE","PERIMETER")

Thickness

Zonal thickness analysis calculates the deepest or thickest point within each zone from its surrounding cells on an input raster. Essentially, it is the radius (in cells) of the largest circle that can be drawn within each zone without including any cells outside the zone.

First, the outermost cells of the zone are identified. Going inward, the cells next to the external cells are identified, then the next, and so forth, until the deepest inward cell is identified.

Distance is calculated from the center of an internal zone cell to the closest edge (not the center) of the closest surrounding cell location.

Deepest inward cell of zone is determined
Deepest inward cell of zone is determined.

The thickness can be calculated from an external border (outside edge) of the zone or from an internal one (an island in the zone).

Thickness from internal or external edge of the zone
Thickness from internal or external edge of the zone

The distance between two adjacent cells that are either directly horizontal or vertical from one another and internal to the zone is 1 times the cell size. If two adjacent cells internal to the zone are diagonal from one another, the distance is ≈1.41421 times the cell size. At the border of the zone, when a cell within the zone comes in contact with a cell outside the zone, the same two formulas above are used, except they are divided by 2. The distance from the internal cells to a border is accumulative.

When the regions within a zone are not connected, zonal thickness returns the value of the deepest cell within all the disconnected regions within the zone.

If one or more boundaries of a zone border the limits of the raster or the analysis window, the borders will be ignored in the calculations. The thickness is only determined for cells inside the extent of the raster or analysis window.

NoData values inside the extent of the raster or analysis window are valid cells for which the thickness will be calculated, but no thickness will be calculated for NoData cells. Cells with NoData as input will result in NoData as output.

Example

The following illustration shows the output of the Zonal Geometry tool on the input raster with Geometry type set to Thickness:

Zonal Geometry illustration
OutRas = ZonalGeometry(InRas1,"VALUE","THICKNESS")

Regarding the influence of the border with zones 7 and -6 in the above example: Even though the two zones have the same cell configuration, zone 7 is one and one-half cells thick, while zone -6 is only one-half cell thick (every cell is an external cell to the zone).

Applications

Zonal thickness analysis answers the question of how far you can walk into a zone, such as a forest, at its deepest point before you are walking out of it.

The zonal thickness can be used for data cleanup to remove small or thin zones that might be noise in the data or irrelevant information for analysis. Once the tool is run, tools in the Conditional and Extraction toolsets, among others, can be used to remove zones that are smaller than some value or thickness. Other useful options for the data cleanup process include the Area and Perimeter outputs, as well as the Generalization tools Boundary Clean, Majority Filter, and Shrink.

Centroid

Zonal centroid analysis approximates the geometry of each zone by creating an ellipse fixed at the centroid of each zonal spatial shape. The eigenvalue and eigenvectors of each zone are calculated. The orientation of the ellipse is in the direction of the first eigenvector. The ratio of the major and minor axes of the ellipse is the same as the ratio of their eigenvalues. The area of each ellipse is equal to the area of the zone it represents.

A centroid will be found for every zone. The cell of the output raster within which a centroid of a zone falls is set to the value of the zone. In general, the number of non-NoData cells in the output raster will be equal to the number of zones in the input raster. However, if two or more zonal centroids would fall within the same output cell, the value of the cell is set to the lowest zone value among those zones.

The ellipse

The attribute table of the output raster contains additional items used to describe the shape of the ellipsoidal approximation of each zone. The parameters defining the shape and size of the ellipse are the major axis, the minor axis, and the orientation. These items are always listed after the Value and Count items in the attribute table. The area of each ellipse is equal to the area of the zone to which it is assigned.

  • MAJORAXIS

    The length of the major axis. It is measured in map units.

  • MINORAXIS

    The length of the minor axis. It is measured in map units.

  • ORIENTATION

    The values of ORIENTATION are in degrees, with a possible range of 0 to 180. The orientation is defined as an angle between the x-axis and the major axis of the ellipse. The values of the orientation angle increase counterclockwise starting at 0 in the east (horizontal, to the right) and going through 90 when the major axis is vertical. If a particular zone consists of only one cell or if the zone is a single square block of cells, the orientation of the ellipse—being a circle in this case—is set to 90 degrees.

Components of the ellipse
Components of the ellipse

Canonical analysis is used to determine the parameters of the ellipses describing all of the zones. The mechanism is commonly referred to as a standard deviation ellipse, where the coordinates of the cell centers serve as the points for which the dispersion is calculated. Consult the reference listed at the end of this document for a general description of the calculations.

Example

The following illustration shows the output of the Zonal Geometry tool on the input raster with Geometry type set to Centroid:

Centroid Zonal Geometry illustration
OutRas = ZonalGeometry(InRas1,"VALUE","CENTROID")
Output attribute table from Zonal Geometry with Centroid option
Output attribute table from Zonal Geometry with Centroid option

References

Ebdon, D., Statistics in Geography. Blackwell, 2001.

Related Topics

11/8/2012