The Generate Multidimensional Anomaly tool computes the anomaly for each slice in an existing multidimensional raster to generate a new multidimensional imagery layer.

The output is a hosted imagery layer.

## Example

You have monthly ocean temperature data, collected every 1 meter of depth up to 100 meters, and you want to calculate the temperature anomalies as deviations from the yearly mean. The Generate Multidimensional Anomaly tool will determine the temperature anomalies based on a yearly mean if you set Yearly as the temporal interval to calculate the mean, and it will return anomaly values for each of the 100 depths.

## Usage notes

Generate Multidimensional Anomaly tool includes configurations for input layer, anomaly settings, and result layer.

### Input layers

The Input layers group includes the following parameters:

- Multidimensional imagery layer is the multidimensional imagery layer that will be used to locate the areas where the observation deviates from its standard, mean, or median value.
- Variables indicates which values will be considered when generating anomalies.

### Anomaly settings

The Anomaly settings group includes the following parameters:

- Anomaly calculation method specifies the method that will be used to calculate the anomaly. The Anomaly calculation method parameter options include the following:
Difference from mean—The difference between a pixel value and the mean of that pixel's value across slices defined by the interval will be calculated.

Difference from mean=x - µ

- x=Pixel value in a slice
- µ=Mean of the pixel's values over the given time interval

Percent difference from mean—The percent difference between a pixel value and the mean of that pixel's value across slices defined by the interval will be calculated.

Percent difference from mean=|x - µ| / [(x + µ)/2]

- x=Pixel value in a slice
- µ=Mean of the pixel's values over the given time interval
- |x - µ|=Absolute value of the difference between the value and the mean

Percent of mean—The percent of the mean will be calculated.

Percent of mean=x / µ

- x=Pixel value in a slice
- µ=Mean of the pixel's values over the given time interval

Z score—The z-score for each pixel will be calculated. A z-score of 0 indicates the pixel's value is identical to the mean. A z-score of 1 indicates the pixel's value is 1 standard deviation from the mean. If a z-score is 2, the pixel's value is 2 standard deviations from the mean, and so on.

Z-score=(x - µ) / S

- x=Pixel value in a slice
- µ=Mean of the pixel's values over the given time interval
- S=The standard deviation of the pixel's values over the given time interval

Difference from median—The difference between a pixel value and the mathematical median of that pixel's values across slices defined by the interval will be calculated.

Difference from median=x - ß

- x=Pixel value in a slice
- ß=Median of the pixel's values over the given time interval

Percent difference from median—The percent difference between a pixel value and the mathematical median of that pixel's values across slices defined by the interval will be calculated.

Percent difference from median=|x - ß| / [(x + ß)/2]

- x=Pixel value in a slice
- ß=Median of the pixel's values over the given time interval
- |x - ß|=Absolute value of the difference between the value and the median

Percent of median—The percent of the mathematical median will be calculated.

Percent of median=x / ß

- x=Pixel value in a slice
- ß=Median of the pixel's values over the given time interval

- Mean calculation interval specifies the temporal interval that will be used to calculate the mean. The external imagery layer can be a single layer or a multidimensional imagery layer. If the input is a single imagery layer, the difference from the mean will be calculated by comparing the pixel values in each slice to the corresponding pixel value in the external imagery layer. If the input is a multidimensional imagery layer, corresponding slices will be compared to calculate the difference from the mean, so the number and name of the variables and dimensions must match.
- All—The mean is calculated across all slices for each pixel.
- Yearly—The yearly mean is calculated for each pixel.
- Recurring monthly—The monthly mean is calculated for each pixel.
- Recurring weekly—The weekly mean is calculated for each pixel.
- Recurring daily—The daily mean is calculated for each pixel.
- Hourly—The hourly mean is calculated for each pixel.
- External raster—An existing imagery layer that contains the mean or median value for each pixel is referenced.

- Reference raster indicates the imagery layers that contain a previously calculated mean for each pixel. The anomalies will be calculated in comparison to this mean.
- Ignore NoData specifies whether NoData values are ignored in the analysis. If checked, the analysis will include all valid pixels along a given dimension and ignore any NoData pixels. This is the default. If unchecked, the analysis will result in NoData if there are any NoData values for the pixels along the given dimension.

### Result layer

The Result layer group includes the following parameters:

- Output name determines the name of the layer that is created and added to the map. The name must be unique. If a layer with the same name already exists in your organization, the tool will fail and you will be prompted to use a different name.
- Save in folder specifies the name of a folder in My Content where the result will be saved.

## Environments

Analysis environment settings are additional parameters that affect a tool's results. You can access the tool's analysis environment settings from the Environment settings parameter group.

This tool honors the following analysis environments:

- Output coordinate system
- Processing extent
##### Note:

The default processing extent in Map Viewer is Full extent. This default is different from Map Viewer Classic in which Use current map extent is enabled by default.

- Snap raster
- Cell size
- Resampling method
- Parallel processing factor

## Outputs

The output includes one thematic imagery layer with the areas that are significantly different from the desired measurement indicated. If the input imagery layer was multidimensional, the output layer will be multidimensional.

## Usage requirements

This tool requires the following licensing and configurations:

## Resources

Use the following resources to learn more:

- Generate Multidimensional Anomaly in ArcGIS REST API
- generate_multidimensional_anomaly in ArcGIS API for Python
- Generate Multidimensional Anomaly in ArcGIS Pro