This document is archived and information here might be outdated.  Recommended version.


IGeneralizeOp.Aggregate Method (ArcObjects .NET 10.8 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > SpatialAnalyst > ESRI.ArcGIS.SpatialAnalyst > Interfaces > IG > IGeneralizeOp Interface > IGeneralizeOp.Aggregate Method
ArcGIS Developer Help

IGeneralizeOp.Aggregate Method

Generates a reduced resolution version of a raster.

[Visual Basic .NET]
Public Function Aggregate ( _
    ByVal Raster As IGeoDataset, _
    ByVal cellFactor As Integer, _
    ByVal aggregationType As esriGeoAnalysisStatisticsEnum, _
    ByVal expandExtent As Boolean, _
    ByVal ignoreNoData As Boolean _
) As IGeoDataset
[C#]
public IGeoDataset Aggregate (
    IGeoDataset Raster,
    int cellFactor,
    esriGeoAnalysisStatisticsEnum aggregationType,
    bool expandExtent,
    bool ignoreNoData
);
[C++]
HRESULT Aggregate(
  IGeoDataset* Raster,
  long cellFactor,
  esriGeoAnalysisStatisticsEnum aggregationType,
  VARIANT_BOOL expandExtent,
  VARIANT_BOOL ignoreNoData
);
[C++]
Parameters
Raster [in]

Raster is a parameter of type IGeoDataset* cellFactor [in]
cellFactor is a parameter of type long aggregationType [in]
aggregationType is a parameter of type esriGeoAnalysisStatisticsEnum expandExtent [in]
expandExtent is a parameter of type bool ignoreNoData [in]
ignoreNoData is a parameter of type bool

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server. Requires Spatial Analyst Extension.

Remarks

raster

an input Raster, RasterDataset, RasterBand, or RasterDescriptor

cellFactor

a factor to multiply the cell size of the input Raster to obtain the desired resolution for the output Raster

A cellFactor of 3 would result in an output cell size that is three times larger than the input raster’s cell size. The cellFactor must be an integer greater than one.

aggregationType

establishes how the value for each output cell will be determined

The output value for each cell can be the sum (esriGeoAnalysisStatsSum), minimum (esriGeoAnalysisStatsMinimum), maximum (esriGeoAnalysisStatsMaximum), mean (esriGeoAnalysisStatsMean), or median (esriGeoAnalysisStatsMedian) value of the input cells that the coarser output cell will encompass.

expandExtent

a Boolean defining how to handle the boundaries of the input raster when its rows and/or columns are not a multiple of the cellFactor

If the number of rows and columns in the input raster is a multiple of the cellFactor this Boolean will not be applied.

A True for the Boolean will expand the bottom and/or right boundaries of the input raster so that the total number of cells in a row and/or column is a multiple of the cellFactor. Expanded cells are given a value of NoData. With a True Boolean, the output raster can cover a larger spatial extent than the input raster.

A False for the Boolean will reduce the number of rows and/or columns in the output raster by one. This will truncate the remaining cells on the bottom and/or right boundaries of the input raster, making the number of rows and/or columns in the input raster a multiple of the cellFactor. With this option, the output raster can cover a smaller spatial extent than the input raster.

ignoreNoData

a Boolean that if True dictates that if a NoData value exists for any of the cells that fall within the spatial extent of a larger cell on the output raster, then the NoData value will be ignored when determining the value for that output cell location

Only input cells within the output cell’s extent that have data values will be used in determining the value of the output cell.

If False, then any cell that falls within the spatial extent of a larger cell on the output raster that has a value of NoData, the value for that output cell location will be NoData. When the Boolean is True, it is implied that when cells within an aggregation contain the NoData value, there is insufficient information to perform the specified calculations necessary to determine an output value.

 

See Also

IGeneralizeOp Interface