Tool Shrink and Expand
The tool allows one to shrink or expand regions with valid data by a certain distance (defined by the kernel radius). Shrinking just invalidates cells with valid data at the border to No Data regions, expanding sets No Data cells along the border of regions with valid data to a new valid value. The tool provides several options how to calculate this new value: minimum, maximum, mean or majority of the valid cells within the kernel.
- Author: V.Wichmann & O.Conrad (c) 2011
- Menu: Grid|Gaps
Parameters
Name | Type | Identifier | Description | Constraints | |
---|---|---|---|---|---|
Input | Grid | Grid, input | INPUT | The input grid. | - |
Output | Result Grid (*) | Grid, output, optional | RESULT | The output grid. | - |
Options | Grid System | Grid system | PARAMETERS_GRID_SYSTEM | - | - |
Operation | Choice | OPERATION | Choose the type of operation. | Available Choices: [0] shrink [1] expand [2] shrink and expand [3] expand and shrink Default: 3 | |
Search Mode | Choice | CIRCLE | Choose the shape of the kernel. | Available Choices: [0] Square [1] Circle Default: 1 | |
Radius | Integer | RADIUS | The kernel radius [cells]. | Minimum: 1 Default: 1 | |
Method | Choice | EXPAND | Choose how to fill no-data cells. | Available Choices: [0] minimum [1] maximum [2] mean [3] majority Default: 3 | |
Preserve Data Type | Boolean | KEEP_TYPE | If false, mean value expansion results will be stored with floating point precision. | Default: 1 | |
(*) optional |
Command-line
Usage: saga_cmd grid_tools 28 [-INPUT <str>] [-RESULT <str>] [-OPERATION <str>] [-CIRCLE <str>] [-RADIUS <num>] [-EXPAND <str>] [-KEEP_TYPE <str>] -INPUT:<str> Grid Grid, input -RESULT:<str> Result Grid Grid, output, optional -OPERATION:<str> Operation Choice Available Choices: [0] shrink [1] expand [2] shrink and expand [3] expand and shrink Default: 3 -CIRCLE:<str> Search Mode Choice Available Choices: [0] Square [1] Circle Default: 1 -RADIUS:<num> Radius Integer Minimum: 1 Default: 1 -EXPAND:<str> Method Choice Available Choices: [0] minimum [1] maximum [2] mean [3] majority Default: 3 -KEEP_TYPE:<str> Preserve Data Type Boolean Default: 1