|
map
|
The map Function applies the specified function {proc}
to each value in {directory}. The map function returns a
directory containing the result of the each mapping. The function
{proc} must be a function that requires a single argument.
The map function is a non-destructive function useful when you want to apply a native or user-defined function to each member in a Directory. As a result, each member of the Directory may be updated by the map function without having to set up a loop and reference each field individually. For instance, the map function, with arguments of {proc} and {directory}, is equivalent to the following generic loop code:
(loop for i from 0 until (length directory) do (proc directory[i]))
(map proc vector) A new vector object containing values that have the values updated by
applying the map function to each value.
Here are a number of links to Lambda coding examples which contain this instruction in various use cases.
Here are the links to the data types of the function arguments. Here are also a number of links to functions having arguments with any of these data types.
You can always talk with the AIS at aiserver.sourceforge.net.
Name
Description
AIS Types proc A function requiring a single argument. Function vector Vector containing the argument values for the function {proc} Vector FltVector ShortVector IntVector NumVector
Returns:
Examples
Argument Types
Structure
Dictionary
NumMatrix
Directory
Vector
Matrix
Pair
List
ShortVector
FltVector
IntVector
NumVector
How do I contact the AIS team?