AVERAGEIF - too many arguments

Swanson

New Member
Joined
Jul 1, 2020
Messages
4
Office Version
  1. 2010
Platform
  1. Windows
  2. MacOS
  3. Mobile
  4. Web
Hello,

My formula below is giving me the message I have too many arguments...Is there a better formula to use if I have a specific criteria that needs to be met and I want the average of values that are greater than 150 and less than 500

=AVERAGEIF('CAR Data'!I235:I287,$J15,">=150",'CAR Data'!M235:M287,"<=500")
 

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK
Welcome to the forum. :)

What is the $J15 bit doing there? It looks like perhaps you should be using AVERAGEIFS like this:

=AVERAGEIFS('CAR Data'!M235:M287,'CAR Data'!I235:I287,$J15,'CAR Data'!M235:M287,">=150",'CAR Data'!M235:M287,"<=500")
 
Upvote 0
lol I was trying to be specific about the criteria to reference. Does it look werid?

'CAR Data'!I235:I287 - range of names some listed multiple times
$J15 - the specific name I wanted to reference. Added the $ so I can pull down the formula
">=150",'CAR Data'!M235:M287,"<=500" average value that are greater than 150 and less than 500

I noticed AVERAGEIFS took but i was getting a value error. let me try your with your help!
 
Upvote 0
it worked. I am getting a #DIV/0 error. I didn't realize with AVERAGEIFS it needs to include both column M and I in the first range
 
Upvote 0
You don't.
Column M is the first argument - the range you want the average of.
Column I is the first criteria range, and J15 is the criterion.
Then you have Column M twice as additional criteria ranges because you only want values >=150 and <=500.

So there are 7 arguments in all.

#DIV/0 means that no values match your criteria.
 
Upvote 0

Forum statistics

Threads
1,214,823
Messages
6,121,779
Members
449,049
Latest member
greyangel23

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