how to find the sum of certain values in a column.
Hi,
You can use any of the following minor additons to those already supplied:
=SUMPRODUCT((A2:A11="B")+(A2:A11="C"),B2:B11)
=SUMPRODUCT((A2:A11={"B","C"})*B2:B11)
or in 2007:
=SUM(SUMIFS(B2:B11,A2:A11,{"B","C"}))
--
If this helps, please click the Yes button
Cheers,
Shane Devenshire
"mrmaw1" wrote:
I want to be able to find the sum of all values in a column that have a
particular value in the previous column, sush as follows.
A B
1 TYPE VALUE
2 a 10
3 b 10
4 a 10
5 c 10
6 b 10
7 a 10
8 c 10
9 b 10
10 c 10
11 a 10
12 TOTAL 100
I'm able to total the column fine but what I want is the following:
A) I want is a formula that will total only those VALUES that are TYPE "a"
so that I can multiply the sum by a factor of Y. In this case the answer
would be 40(Y).
B) And I want a different formula that will total those VALUES that are
either TYPE "b" or "c" so that I can multiply the sum by a factor of Z. In
this case the answer would be 60(Z).
Any help would be greatly appreciated.
Thank you.
|