Sumproduct

  • Thread starter Thread starter Mark
  • Start date Start date
M

Mark

From a posting reply yesterday, I am trying to use
sumproduct to count the number of occurrences of "so" in
column N that also have "Y" in column R. I used the
following:

=SUMPRODUCT(N4:N25="so",R4:R25="y")

For some reason, this is returning the value of zero. I
do know that the conditions are TRUE for 3 occurences, so
the sum product should be 3.

Any ideas what I am doing wrong?

Thanks,
Mike.
 
Mark said:
From a posting reply yesterday, I am trying to use
sumproduct to count the number of occurrences of "so" in
column N that also have "Y" in column R. I used the
following:

=SUMPRODUCT(N4:N25="so",R4:R25="y")

For some reason, this is returning the value of zero. I
do know that the conditions are TRUE for 3 occurences, so
the sum product should be 3.

Any ideas what I am doing wrong?

Thanks,
Mike.

SUMPRODUCT requires numeric arguments but you have Boolean (True/False)
ones. There are several ways of dealing with this, including the following:
=SUMPRODUCT((N4:N25="so")*(R4:R25="y"))
=SUMPRODUCT(--(N4:N25="so"),--(R4:R25="y"))
=SUMPRODUCT((N4:N25="so")*1,(R4:R25="y")*1)
 
Thanks, Paul!
-----Original Message-----


SUMPRODUCT requires numeric arguments but you have Boolean (True/False)
ones. There are several ways of dealing with this, including the following:
=SUMPRODUCT((N4:N25="so")*(R4:R25="y"))
=SUMPRODUCT(--(N4:N25="so"),--(R4:R25="y"))
=SUMPRODUCT((N4:N25="so")*1,(R4:R25="y")*1)


.
 
Back
Top