collection/
mg_max.pro
Routines
top mg_max
result = mg_max(iterable [, max_subscript] [, key_method=string] [, key_function=string] [, /absolute] [, dimension=long] [, min=any] [, /nan] [, subscript_min=any])
Returns maximum of an array or object which supports FOREACH loops.
Return value
any
Parameters
- iterable in required type=array/object
array or object which supports FOREACH loops
- max_subscript out optional type=any
array index or key type of object corresponding to the maximum value of
iterable
Keywords
- key_method in optional type=string
name of method to call on the items of
iterable
to determine their value; this method should be a function with no arguments required and returning a type which supports comparing with GT and LT- key_function in optional type=string
name of function to determine the value of the items of
iterable
; this function should accept one positional parameter (the item ofiterable
) and return a type which supports comparing with GT and LT- absolute in optional type=boolean
set to use the absolute value of the values in
iterable
to compare for the minimum/maximum value, though the return value will be the original value initerable
- dimension in optional type=long
dimension over which to find the minimum values of an array when
iterable
is an array andKEY_FUNCTION
is not used; otherwise it is ignored- min out optional type=any
minimum value
- nan in optional type=boolean
set to ignore NaN values in arrays; not used if
iterable
is an object or ifKEY_FUNCTION
is present- subscript_min out optional type=any
array index or key type of object corresponding to the minimum value of
iterable
File attributes
Modification date: | Wed May 14 15:07:14 2014 |
Lines: | 90 |
Docformat: | rst rst |
Contact me if you have enhancement requests or bug fixes.