average calculation

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

using the formula below i've been able to get the sum of column B if the
corresponding cell in column A says "spring". my question is
how can i do the same thing but to get the AVERAGE instead of the SUM.

=SUMPRODUCT(--(A2:A14="spring"),(B2:B14))
 
Hi!
=SUMPRODUCT(--(A2:A14="spring"),(B2:B14))

Better:

=SUMIF(A2:A14,"spring",B2:B14)

Best:

C1 = spring

=SUMIF(A2:A14,C1,B2:B14)

For the average:

=SUMIF(A2:A14,C1,B2:B14)/COUNTIF(A2:A14,C1)

Biff
 

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

Similar Threads

sumif with 2 variables 2
Sum Worksheets 7
Weighted Average 7
help copying formulas 1
Multiple criteria question 1
Find Average using Sumproduct 3
Excel Sumproduct 0
Average weekly maximum 3

Back
Top