StatisticsOp Operator

StatisticsOp Operator Description

Overview

Name:StatisticsOp
Full name:org.esa.snap.statistics.StatisticsOp
Purpose:Computes statistics for an arbitrary number of source products.
Version:1.0

Description

An operator that is used to compute statistics for any number of source products, restricted to time intervals and regions given by an ESRI shapefile. If no time intervals are defined, statistics are aggregated over the whole period. If no region is given, all pixels of a product are considered.

The operator writes two different sorts of output:

Unlike most other operators, that can compute single {@link Tile tiles}, the statistics operator processes all of its source products in its {@link #doExecute(ProgressMonitor)} method.

Sources

Name Description
sourceProducts The source products to be considered for statistics computation. If not given, the parameter 'sourceProductPaths' must be provided.

Parameters

Name Data Type Default Description Constraints
sourceProductPaths String[] A comma-separated list of file paths specifying the source products. Each path may contain the wildcards '**' (matches recursively any directory), '*' (matches any character sequence in path names) and '?' (matches any single character). If, for example, all NetCDF files under /eodata/ shall be considered, use '/eodata/**/*.nc'.
shapefile File An ESRI shapefile, providing the considered geographical region(s) given as polygons. If null, all pixels are considered.
featureId String name The name of the attribute in the ESRI shapefile that shall be used to identify featuresin the output. If none is given or if the shapefile does not have the attribute, the feature id will beused. This parameter is case-sensitive. It is only considered when the shapefile parameter is set.
startDate UTC The start date. If not given, taken from the 'oldest' source product. Products that have a start date before the start date given by this parameter are not considered. format: yyyy-MM-dd HH:mm:ss
endDate UTC The end date. If not given, taken from the 'youngest' source product. Products that have an end date after the end date given by this parameter are not considered. format: yyyy-MM-dd HH:mm:ss
bandConfigurations BandConfiguration[] The band configurations. These configurations determine the input of the operator. not null
outputShapefile File The target file for shapefile output. Shapefile output will only be written if this parameter is set. The band mapping file will have the suffix _band_mapping.txt.
outputAsciiFile File The target file for ASCII output.The metadata file will have the suffix _metadata.txt. ASCII output will only be written if this parameter is set.
percentiles int[] 90,95 The percentile levels that shall be created. Must be in the interval [0..100]
accuracy int 3 The degree of accuracy used for statistics computation. Higher numbers indicate higher accuracy but may lead to a considerably longer computation time.
interval TimeIntervalDefinition If set, the StatisticsOp will divide the time between start and end time into time intervalsdefined by this parameter. All measures will be aggregated from products within these intervals. This parameter will only have an effect if the parameters start date and end date are set.
writeDataTypesSeparately boolean false If true, categorical measures and quantitative measures will be written separately.