# Partial sums of a column of values

I have a column of values like this:

0`

1

3

0

0

12

45

56

0

How do I compute the subtotals of contiguous nonzero numbers?

First time here? Check out the FAQ!

Partial sums of a column of values

0`

1

3

0

0

12

45

56

0

How do I compute the subtotals of contiguous nonzero numbers?

add a comment

0

See this example.

===Edit1: Enhanced Example===

Here it is.

Thanks! I understand that the A2:A1001 is assumed to be the maximum run the data can have?

~~It's not just the maximum run (of non-zero values), but the maximum range of any values.~~

You were right - basically. The range of 1000 rows moves down with the starting row. That's not a really satisfying solution. (It seems I had a kind of blackout.)

To expand the range without too much decrease in efficiency can be achieved using helper formulae that only need to look at two rows instead of many. The partial sums can then be taken from a "Pivot Table".

See the enhanced example.

Wow, you already did what I have to accomplished next. Thank you very much!

Asked: ** 2019-02-23 01:53:51 +0200 **

Seen: **122 times**

Last updated: **Feb 23 '19**

How do I export a chart in an image format from LibreOffice Calc? [closed]

Are there plans for a "papercut" project for libreoffice [closed]

Is it normal for Calc goal seek to take very long? [closed]

Please refine "Search" in Calc - implement functions in Gnumeric [closed]

LibreOffice Calc will not link to external data via internet [closed]

Is there a LibreOffice .odt, .ods viewer for Android? [closed]

Why is Calc so much slower at opening/saving files than MS-Office? (win7 x64) [closed]

Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.