Most grading rubrics assign different weights to the midterm and final scores. Some might give the final extra weight. Others give the final equal or smaller weight.
Here is a formula based solution where you can adjust the weighting when generating the overall grade.
For example we could make the final count for 60% of the overall grade.
data want;
set have;
excluded=-min(of exam1-exam5);
if n(of exam1-exam5) < 5 then excluded=0;
exams = sum(of exam1-exam5 excluded)/4;
final_wt=0.6;
exam_wt=0.4;
grade = exam_wt*exams + final_wt*final;
run;
So with that weighting the study with the higher final score gets a better overall grade.
Obs id exam1 exam2 exam3 exam4 exam5 final excluded exams final_wt exam_wt grade
1 1 100 100 100 100 0 90 0 100 0.6 0.4 94
2 2 90 90 90 90 85 100 -85 90 0.6 0.4 96
If you want each of the included exams and the final to have equal weight then use FINAL_WT=.2 and EXAM_WT=.8.
Now the student with the higher mid term scores does better than the student with the higher final score.
Obs id exam1 exam2 exam3 exam4 exam5 final excluded exams final_wt exam_wt grade
1 1 100 100 100 100 0 90 0 100 0.2 0.8 98
2 2 90 90 90 90 85 100 -85 90 0.2 0.8 92
... View more