docs-v2/content/influxdb/cloud/reference/flux/stdlib/math/mmin.md

882 B

title description aliases menu weight
math.mMin() function The math.mMin() function returns the smaller of `x` or `y`.
/influxdb/cloud/reference/flux/functions/math/m_min/
/influxdb/cloud/reference/flux/stdlib/math/m_min/
influxdb_cloud_ref
name parent
math.mMin Math
301

The math.mMin() function returns the smaller of x or y.

Output data type: Float

import "math"

math.mMin(x: 1.23, y: 4.56)

// Returns 1.23

Parameters

x

The X value used in the operation.

Data type: Float

y

The Y value used in the operation.

Data type: Float

Special cases

math.mMin(x:x, y: -Inf) // Returns -Inf
math.mMin(x: -Inf, y:y) // Returns -Inf
math.mMin(x:x, y: NaN)  // Returns NaN
math.mMin(x: NaN, y:y)  // Returns NaN
math.mMin(x: -0, y: ±0) // Returns -0
math.mMin(x: ±0, y: -0) // Returns -0