ee.Array.min

On an element-wise basis, selects the minimum of the first and second values.

UsageReturns
Array.min(right)Array
ArgumentTypeDetails
this: leftArrayThe left-hand value.
rightArrayThe right-hand value.

Examples

Code Editor (JavaScript)

var empty = ee.Array([], ee.PixelType.int8());
print(empty.min(empty));  // []

print(ee.Array([0, 1, 2, 3]).min(ee.Array([-1, 3, 0, 2])));  // [-1,1,0,2]

Python setup

See the Python Environment page for information on the Python API and using geemap for interactive development.

import ee
import geemap.core as geemap

Colab (Python)

empty = ee.Array([], ee.PixelType.int8())
display(empty.min(empty))  # []

# [-1, 1, 0, 2]
display(ee.Array([0, 1, 2, 3]).min(ee.Array([-1, 3, 0, 2])))