Re: adding cells within an array
- From: "Bernard Liengme" <bliengme@xxxxxxxxxxxxxxxxx>
- Date: Wed, 23 Aug 2006 20:58:17 -0300
Not very fancy but here goes.
Assuming you data is in A1:A(whatever)
In B1 enter =IF(AND(A1<>0,A2=0),SUM($A$1:A1),"") and copy down the column
IN C2 (NOT C1) enter =IF(ISERROR(B2-SUM($B$1:B1)),"",B2-SUM($B$1:B1)) and
copy down the column
Hide column B if required
best wishes
--
Bernard V Liengme
www.stfx.ca/people/bliengme
remove caps from email
"beecher" <beecher@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:A11C22F9-7132-42B3-A3B6-6CC38E83F61C@xxxxxxxxxxxxxxxx
I'm trying to devise a way to add cells within an array following a set of
criteria.
I have an array with a series of zero and non-zero numbers. As an
example:
1 0
2 0
3 1.2
4 1.3
5 1.4
6 0
7 1.1
8 1.8
9 0
10 0
I want to add all the numbers that are between the zeroes. That is, I
would
like to have two separate values in the above example: one value that is
the
sum of 1.2, 1.3, and 1.4 and a second value that equals the sum of
1.1+1.8.
I could manually go through the array and add each sum, but because there
are
nearly 40 sums in each array and multiple arrays to do this calculation I
would like to find a function to perform this task for me. Any help would
be
much appreciated.
.
- Prev by Date: Re: adding cells within an array
- Next by Date: Re: Personal.xls
- Previous by thread: Re: adding cells within an array
- Next by thread: Re: adding cells within an array
- Index(es):
Relevant Pages
|
Loading