Using AVERAGEIF & ISERROR together

28creation

Board Regular
Joined
Oct 13, 2014
Messages
124
Hi all,


I'm producing an average of G9-K9, but only if the result is over 0, so I have this initial formula:

=AVERAGEIF(G9:K9,"<>0")

This works fine.


But I'm trying to include an ISERROR so if there's no results in the boxes specified the cell will produce a blank box rather than #DIV/0!.

I've tried to use an example formula off another spreadsheet & it's not working:

=AVERAGEIF(ISERROR(G9:K9,"<>0"),"",G9:K9).


Hope someone can point me in the right direction.

Thanks.
 

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.
I think you want this:

Code:
=IFERROR(AVERAGEIF(G9:K9,"<>0"),"")
 
Upvote 0
Trying to remove the #DIV/0! error for zeros in an AVERAGEIF formula with a specific search criteria from another table. The formula I am using is:

=AVERAGEIF($D$9:$D$1508,"="&F$2,$I$9:$I$1508)

. . . but I can't figure out how to get the calculation to report a zero instead of the #DIV/0! error. I tried incorporating the ISERROR but can't get the formula right.
 
Upvote 0
How about
Excel Formula:
=IFERROR(AVERAGEIF($D$9:$D$1508,F$2,$I$9:$I$1508),0)
 
Upvote 0
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,214,551
Messages
6,120,161
Members
448,948
Latest member
spamiki

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