I have two columns. Column A & Column B. Column A is either "buy" or "sell." Column B is some arbitrary number.
I want to sum column B until Column A changes its value.
E.g.
A B
Buy 5
Buy 1
Buy 4
Sell 3
Buy 2
Sell 4
Sell 4
Should become
A B
Buy 10
Sell 3
Buy 2
Sell 8
I'm going to build it out to something more complex later which includes multiple columns but it's all based on this idea of doing some operation until the Column value changes.
Any suggestions or ideas?
Bookmarks