function max
Returns the maximum value of an array or the maximum of two real numbers. Undefined values (INF and NaN) are ignored.
Syntax
result = max(X [, ignore] [,/x | /y | /z | /xy | /xz | /yz])
result = max(a, b)
Arguments
X: | A matrix. |
ignore: | An optional value which should be ignored. |
a: | A real number. |
b: | A real number. |
Switches
/x: | Calculate the maximum along the first axis |
/y: | Calculate the maximum along the second axis |
/z: | Calculate the maximum along the third axis |
/xy: | Calculate the maximum along the first and second axes |
/xz: | Calculate the maximum along the first and third axes |
/yz: | Calculate the maximum along the second and third axes |
Examples
To get a 1D vector of the maxima of all slices along a 3D cube:
result = max(cube, /xy)
See also
function min
function avg
function total
function median
function stddev
function meddev
function variance