Finding the average of 4 highest of 6 numbers

Cornelius Morris

New Member
Joined
Nov 27, 2008
Messages
30
I need to figure the average of the 4 highest of 6 quiz scores for a class that I am teaching. I drop the two lowest scores, but those are the two lowest submitted quizzes; a zero (= student skipped the quiz) does not count as one of the two dropped.

So: a sample student has these six cells:
P3 (83), Q3 (67), R3 (58), S3 (0), T3 (17), U3 (50).

I want to drop the 17 and the 50.

Thanks in advance for any suggestions.

Cornelius
 

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
Perhaps:
=AVERAGE(LARGE((IF(P3:U3>0,P3:U3)),ROW(INDIRECT("1:"&4-COUNTIF(P3:U3,0)))))

Confirm with CTRL-SHIFT-ENTER rather than just Enter.
 
Upvote 0
Another way :

=AVERAGE(IFERROR(LARGE(P3:U3,{1,2,3,4}-COUNTIF(P3:U3,"=0")),""))

Confirm with CTRL-SHIFT-ENTER
 
Last edited:
Upvote 0
I must have understood the question differently - I came up with

=(SUM(LARGE(IF(P3:U3=0,999,P3:U3),{1,2,3,4}))-COUNTIF(P3:U3,0)*999)/4
confirmed with Control+Shift+Enter.

It returns 52 = (83+67+58+0)/4
 
Upvote 0
This non array formula should give you the same result as Eric's

=(SUM(P3:U3)-SUM(SMALL(P3:U3,{1,2}+MIN(4,COUNTIF(P3:U3,0)))))/4
 
Upvote 0
Thanks, everyone. I got the result with Eric's and Barry's versions.

Yes, I wasn't dropping the zero; the student gets the two lowest quizzes dropped, but gets no break if the quiz isn't submitted.

Cornelius
 
Upvote 0

Forum statistics

Threads
1,223,898
Messages
6,175,272
Members
452,628
Latest member
dd2

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