Average with Conditions

C

Curtis

I need to a formula that will look at column c and if it contains a certain
text say "dog" I want to average the price located in column H

Thanks
 
T

T. Valko

Try one of these...

Excel 2007 or later:

=AVERAGEIF(C2:C10,"dog",H2:H10)

Any version of Excel:

=SUMIF(C2:C10,"dog",H2:H10)/COUNTIF(C2:C10,"dog")

This one is array entered:

=AVERAGE(IF(C2:C10="dog",H2:H10))

** array formulas need to be entered using the key combination of
CTRL,SHIFT,ENTER (not just ENTER). Hold down both the CTRL key and the SHIFT
key then hit ENTER.
 
O

ozgrid.com

I would avoid array formulas and simply use;
=SUMIF(C1:C100,"dog",H1:H100)/COUNTIF(C1:C100,"dog")
 

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