SheetRocks
Documentation/Formulas/MAP

MAP

Processes each row in an array with a formula including a COL or CELL keyword and returns it as a 2D array.

Syntax

MAP(array, lambda)

Arguments

Argument Description Required
array The array to process Required
lambda The lambda function to apply to each row Required

Examples

Double each value in array

=MAP(A1:A4, COL[1]*2)
Result ⇒ Array: [[2], [4], [6], [8]]
A
1 1
2 2
3 3
4 4

Calculate square of each number

=MAP(A1:A3, CELL^2)
Result ⇒ Array: [[25], [100], [225]]
A
1 5
2 10
3 15

Convert temperatures from Celsius to Fahrenheit

=MAP(A1:A3, COL[1]*9/5+32)
Result ⇒ Array: [[32], [68], [212]]
A
1 0
2 20
3 100

Related Functions

Other Data functions:


← Back to Formula Reference