Jump to content

What's the best way to grab a value from a prior row in a calculated column?

Dan Kellem

Recommended Posts

Given a data set like this:

Group Index Data Calc

A 1 a 0

A 2 b b-a

A 3 c c-b

A 4 d d-c

A 5 e e-d

B 1 f 0

B 2 g g-f

B 3 h h-g

B 4 i i-h

B 5 j j-i

For a given row (like Group A, Index 3), how would you create a calculated column as the difference from the data in that cell © with the data in the same Group, but prior Index (b)? The first row in each group is handled easily with a case statement.

Spreadsheet w/ data above attached.


Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...