Buat offset referensi dari titik awal yang diberikan
=OFFSET(reference, rows, cols, [height], [width])
| Parameter | Deskripsi |
|---|---|
reference |
The starting point, supplied as a cell reference or range. |
rows |
The number of rows to offset below the starting reference. |
cols |
The number of columns to offset to the right of the starting reference. |
height |
[optional] The height in rows of the returned reference. |
width |
[optional] The width in columns of the returned reference. |
For example, to reference C5 starting at A1, reference is A1, rows is 4 and cols is 2:
=OFFSET(A1,4,2) // returns reference to C5
To reference C1:C5 from A1, reference is A1, rows is 0, cols is 2, height is 5, and width is 1:
=OFFSET(A1,0,2,5,1) // returns reference to C1:C5
It is common to see OFFSET wrapped in another function that expects a range. For example, to SUM C1:C5, beginning at A1:
=SUM(OFFSET(A1,0,2,5,1)) // SUM C1:C5
In the screen below, we use OFFSET to return the third value (March) in the second column (West). The formula in H4 is:
=OFFSET(B3,3,2) // returns D6
In the screen below, we use OFFSET to return the last value (June) in the third column (North). The formula in H4 is:
=OFFSET(B3,6,3) // returns E9
Below, we use OFFSET to return all values in the third column (North). The formula in H4 is:
=OFFSET(B3,1,3,6) // returns E4:E9