Statistical AVERAGEIF
AVERAGEIF(criteria_range, criterion, [average_range]) Returns the average of a range depending on criteria. Learn more