Resample#
Signature#
- downscale(array, cell_size, count, strategy) Field #
Downscale the array by splitting cells into count by count new cells
- Parameters:
array (Field) – Array to downscale
count (Count) – Number of output cells (≥ 1) to create per input cell, in each dimension
strategy (DownscaleStrategy) – Strategy for computing values for the output cells
- Returns:
New array
Description#
Downscaling resamples an input array and creates an output array with a higher resolution.
No-data handling#
Input cells containing no-data values result in no-data values in the corresponding output cells.
Example#
Downscale an array by splitting each cell into four cells (2 by 2) and assigning values from the source array to the target array.
/* TODO */
target_array = downscale(source_array, 2, DownscaleStrategy.assign)
// TODO
target_array = downscale(source_array, 2, DownscaleStrategy.assign)