I have a column (column E) with integer values, and another column (F) with arbitrary values. I want to compute, in column G, the running total of F, but limited to the segment of consecutive rows where the current value of [ICODE]F[/ICODE] is constant. The description may be easier to understand with formulas:
I don't know in advance how long the sequence will be and I would like to use an array formula to automatically adjust the length of the output, instead of repeating the formula in G2 in the G column.
The following formula works:
but is much slower than the G2 formula above: it becomes slow when the sequence has a length in the thousands, while the G2 formula can easily handle hundreds of thousands of values.
How can I make the array formula as fast as the non-array formula?
(and BTW, why is the array formula so slow? All operations inside it should be very fast.)
Bookmarks