Calculating Average only if the difference between the values is less than 10%

MurdochQuill

Board Regular
Joined
Nov 21, 2020
Messages
84
Office Version
  1. 365
Platform
  1. Windows
Hi,

As per title, I'm calculating the average of unique ID's in my list via:
Excel Formula:
=AVERAGEIF($A$2:$A$110, A2, $B$2:$B$110)

ID:ValueAverage
Example1
10​
10.75​
Example1
15​
10.75​
Example1
12​
10.75​
Example2
59​
54.66667​
Example2
60​
54.66667​
Example3
100​
100​
4Example
500​
505​
4Example
510​
505​
Example1
6​
10.75​
Example2
45​
54.66667​


What I would like to do, is output an exception ("INVALID AVERAGE") if the difference between the lowest value and highest value for each unique ID being used in the AVERAGEIF is greater than 10%.

Any help would be appreciated, cheers.
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
I believe you have MINIFS and MAXIFS with Office 365

So maybe like. IF(MAXIFFS(Bla Bla)>(MINIFS(Bla bla)*1.1),"INVALID AVERAGE",AVERAGEIF($A$2:$A$110, A2, $B$2:$B$110))
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,176
Members
453,021
Latest member
Justyna P

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