This is probably a really easy question to answer but it’s been bugging me for ages now! Say I have a range of values in a column sorted like:
Sales:
1500
160
40
300
200
Within this range, I know that the average is 440.
What I would like is for Excel to find the most average value within this range (the closest value to 440 in that range is hence 300). So what can I do for Excel to return 300 as the closest value to the average value within that range?
Thanks so much!
Assuming that the the values are from Cell A2 to A6, use this array formula
You have to press CTL + SHIFT + ENTER after you enter the formula.
SCREENSHOT
FOLLOWUP
Simply use
SUMandCOUNTIFinstead ofAVERAGEin this caseUse this formula
=INDEX(A2:A7,MATCH(MIN(ABS(A2:A7-(SUM(A2:A7)/COUNTIF(A2:A7,"<>0") ))),ABS(A2:A7-(SUM(A2:A7)/COUNTIF(A2:A7,"<>0") )),0))SCREENSHOT