AVERAGEIF Question

dzilla

New Member
Joined
Jan 13, 2014
Messages
6
Hi all,

I am sure this is pretty basic for most of you, but I am truly a novice in Excel formulas so here goes. I would like to display the results of the average of 2 different cells but only if the average of the two cells is less than a specified amount. The problem I am having is that if the average of the 2 cells is greater than the specified amount, the formula cell automatically displays the value of cell #1, when I wish it would display 0 (zero). So for example:

=AVERAGEIF(B9:D9,"<20")

Is there an additional argument that I can add to have the formula display a zero in the event that the average of B9 and D9 is greater than 20?

Thank you all!
 

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.
Im confused? If your average formula is only taking values less than 20 into account, then the average cannot possibly be greater than 20??
 
Upvote 0
Im confused? If your average formula is only taking values less than 20 into account, then the average cannot possibly be greater than 20??

When there is no value < 20 in B9:D9 or B9:D9 contains no numbers, the formula will end up in #DIV/0!.
 
Upvote 0
Aladin, my question was in response to the OP's comment...
Is there an additional argument that I can add to have the formula display a zero in the event that the average of B9 and D9 is greater than 20?

I understand that >20 will produce an error, and maybe that is what they meant (on thinking about it again) :)
 
Upvote 0
Indeed, just a mistype there. Any idea how to have that value be zero?

Aladin, my question was in response to the OP's comment...


I understand that >20 will produce an error, and maybe that is what they meant (on thinking about it again) :)
 
Upvote 0

Forum statistics

Threads
1,214,613
Messages
6,120,515
Members
448,968
Latest member
Ajax40

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top