Skip to contents

Elementwise maximum of two mlx arrays

Usage

mlx_maximum(x, y)

Arguments

x

An mlx array, or an R array/matrix/vector that will be converted via as_mlx().

y

A second array, with the same accepted types as x.

Value

An mlx array containing the elementwise maximum.

See also

Examples

mlx_maximum(1:3, c(3, 2, 1))
#> mlx array [3]
#>   dtype: float32
#>   values:
#> [1] 3 2 3