Quantcast
Channel: Hot Weekly Questions - Web Applications Stack Exchange
Viewing all articles
Browse latest Browse all 9782

Cell specifying the running total length

$
0
0

Context

Here column C contains a running total of the last 5 items from column B.

enter image description here

Formula

The formula is straightforward:

enter image description here

Question

In the above, it's hardcoded for a running total of 5.

What's a good way to have the running total length specified in a separate cell instead of being hardcoded to 5?

I.e. something like this:

enter image description here

so that the user can easily change the 5 to a 7 to get a running total of the last 7.

Link to doc

Link to the spreadsheet shown above.


Viewing all articles
Browse latest Browse all 9782

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>