AVERAGEIF function in Excel
The AVERAGEIF function in Excel is a statistical function that calculates the arithmetic mean of a range of numbers that meet a certain criteria. The arithmetic mean is the sum of the numbers divided by the count of numbers in the range.
The syntax for the AVERAGEIF function is as follows:
scssCopy code
=AVERAGEIF(range, criteria, [average_range])
where:
- range:
The range of cells to be evaluated by the criteria.
- criteria:
The criteria used to determine which cells to include in the calculation.
It can be a number, expression, cell reference, or text string.
- average_range:
[Optional] The range of cells that contains the numbers to be averaged. If
omitted, the function uses the cells in the range parameter.
The AVERAGEIF function returns the arithmetic mean of the
cells in the average_range that meet the specified criteria.
Here's an example of how to use the AVERAGEIF function:
Suppose you have a data set of exam scores for a class of
students, and you want to calculate the average score for students who scored
above 80. You can use the AVERAGEIF function as follows:
lessCopy code
=AVERAGEIF(A2:A20,">80")
In this example, the AVERAGEIF function calculates the
arithmetic mean of the scores in cells A2:A20 that are greater than 80.
Note that the AVERAGEIF function ignores empty cells, text
values, and logical values in the range. Also, the criteria can include logical
operators (>, <, >=, <=, <>, =) or wildcard characters (*, ?)
to match patterns in text values. If you want to include multiple criteria, you
can use the AVERAGEIFS function.
Comments
Post a Comment