powered by
rray_clip() sets inclusive lower and upper bounds on the values of x.
rray_clip()
x
rray_clip(x, low, high)
A vector, matrix, array or rray.
A single value. The lower bound. low is cast to the inner type of x.
low
A single value. The upper bound. high is cast to the inner type of x.
high
Other math functions: remainder, rray_abs, rray_maximum, rray_multiply_add, rray_sign
remainder
rray_abs
rray_maximum
rray_multiply_add
rray_sign
# NOT RUN { # bound `x` between 1 and 5 x <- matrix(1:10, ncol = 2) rray_clip(x, 1, 5) # }
Run the code above in your browser using DataLab