Sumproduct

P

PA

A brief explanation would be appreciated:
What is the difference between
=sumproduct((A2:A100),(B2:B100))
versus
=sumproduct((A2:A100)*(B2:B100))

I have been reading about the many uses of this function, and can not figure
this out

Thanks
Paul
 
B

Bob Phillips

Paul,

The first formula lets the function multiply the two arrays together, as SP
was designed to do.

The second multiples the two arrays by use of the * operator and passes the
resultant array to function as a single array, which SP can simply SUM the
elements, so it does not use the product part of SP, just the SUM part. In
that respect, it is redundant.

The operators in SUMPRODUCT are usually used when conditional tests are
introduced so as to resolve TRUE/FALSE arrays to 1/0 arrays that can be
summed.

Have you see this page http://www.xldynamic.com/source/xld.SUMPRODUCT.html

--

HTH

RP
(remove nothere from the email address if mailing direct)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top