OFFSET

Offsets values within a column

OFFSET( column, number of rows)

Returns a reference to a row relative to the current row, determined by the input number of rows. If number of rows is 0, returns the current row.

Arguments

Argument

Description

column

Column to return

number of rows

Number of rows to offset. number of rows can be positive or negative.

Output

Values in column, offset by the given integer

Example

Let's say we want to calculate the daily percent change in the SPY Index price. We could utilize OFFSET() in such a case to give us the previous day's price, allowing for a manual calculation of the daily percent change to then take place.

Last updated