Thread: Count Function
View Single Post
  #9   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Richard Buttrey
 
Posts: n/a
Default Count Function

On Tue, 14 Mar 2006 05:58:34 -0800, MO
wrote:

Richard,

I was off on 3/13. It "kinda" works! However, there are two counts I need.
I need the cound of all N, E, S, W by column and then a total of all x's in
each column. Here's another sample of what I'm trying to do. I manually put
totals in where I need them. Any other assistance you can provide is truly
appreciated. Thank you so much for your patience.

x N
x E
x S
x W
x S
x E
x N
x N
x N
x E
TOTALS
N 2 2
E 1 2
S 2 0
W 1 0
TOTALS 6 2



Hi,

The SUMPRODUCT formula works for me OK.

Just to repeat. Put your example table above in A1:C10 (i.e. the x's
in columns A & B and the N, E, S W etc in Col C.

Then in E1:E4 enter N, E, S & W

Then in F1 enter

=SUMPRODUCT((A$1:A$10="x")*($C$1:$C$10=$E1))

This will result in '2' i,e the number of N's in col 1.

Now copy this formula to F1:G4 and you should have the small summary
table you identify above.

The totals of all the x's is of course a simple SUM(F1:F4) formula in
F5 and SUM(G1:G4) in G5

Was it a typo above when you say the total number of x's in col B is
2. Surely that should be 4?

If I'm still misunderstanding your problem, please post back.

Rgds















__
Richard Buttrey
Grappenhall, Cheshire, UK
__________________________