Compute Mean in Excel: Easy Guide to the AVERAGE Function
In this article
To compute the mean (average) in Excel, use the =AVERAGE() function. Simply click on the cell where you want the result to appear, type =AVERAGE(, select the range of cells containing your numbers, and press Enter. This achieves a mathematical mean by summing all selected values and dividing by the count of those values automatically.
What You'll Need
- A computer with Microsoft Excel installed (works on Windows, macOS, and Excel for the Web).
- A dataset consisting of numbers organized in cells (rows or columns).
Step-by-Step
- Prepare your data: Ensure your numbers are entered into a continuous range of cells. For example, put your values in cells A1 through A10. Make sure there are no text characters (like "kg" or "lbs") inside the cells with the numbers, as this can interfere with the calculation.
- Select the destination cell: Click on the empty cell where you want the mean to be displayed. This is typically the cell immediately below or to the right of your data range.
- Enter the formula: Type
=AVERAGE(into the cell. The equals sign tells Excel you are starting a formula, and "AVERAGE" is the specific function used to find the mean. - Define the range: You have three ways to select your data:
- Click and Drag: While the cursor is still inside the parentheses, click the first cell of your data (e.g., A1) and drag your mouse to the last cell (e.g., A10).
- Manual Entry: Type the range manually, such as
A1:A10. - Individual Selection: If your numbers are not in a row, hold the Ctrl key (Cmd on Mac) and click individual cells.
- Close and execute: Type the closing parenthesis
)and press the Enter key on your keyboard. Excel will now display the mean of the selected numbers.
Common Mistakes
- Including the Label: Selecting the header cell (e.g., the cell that says "Price") in your range. While the AVERAGE function usually ignores text, it is best practice to select only the numeric data to avoid errors in more complex formulas.
- Typing "Mean" instead of "Average": Excel does not have a function called
=MEAN(). If you type this, you will receive a#NAME?error. You must use=AVERAGE(). - Mixing Data Types: Entering numbers as text. If a number is left-aligned in a cell by default, Excel might be treating it as text, which means the AVERAGE function will ignore it, leading to an incorrect mean.
- Circular References: Placing the formula inside the range you are averaging. For example, if you are averaging A1 through A10, do not put the formula in cell A5. This creates a circular reference and will result in an error.
Tips
- AutoSum Shortcut: For a faster method, highlight the cells you want to average, go to the Home tab, find the AutoSum dropdown menu (the $\Sigma$ symbol), and select Average. Excel will automatically place the mean at the bottom of the selection.
- Quick View: If you don't need the result written in the sheet, simply highlight a group of cells. Look at the Status Bar at the very bottom of the Excel window; it automatically displays the Average, Count, and Sum of the selected cells.
- AVERAGEA for Mixed Data: If you have a list that includes text or "FALSE" values that you want to count as 0 in your mean, use the
=AVERAGEA()function instead of the standard AVERAGE. - Named Ranges: If you frequently average the same set of data, highlight the range, right-click, and select Define Name (e.g., "SalesData"). You can then simply type
=AVERAGE(SalesData).
Troubleshooting
If the result is not what you expected, try these steps in order:
- Check for #DIV/0! Error: This happens if the range you selected is empty or contains only text. Ensure there is at least one numeric value in the selected range.
- Check for #VALUE! Error: This usually occurs if the formula is trying to process a cell that contains an error itself. Scan your data for other error codes and fix them first.
- Verify Number Formatting: Select your data and go to the Home tab. In the "Number" group, ensure the dropdown is set to General or Number rather than Text.
- Check for Hidden Rows: The standard AVERAGE function includes values in hidden rows. If you have filtered your data and only want the mean of the visible cells, use the
=SUBTOTAL(1, range)function instead.
Frequently Asked Questions
Does the mean include zero values?
Yes, the AVERAGE function includes cells containing 0 in the calculation. However, it completely ignores empty cells (blanks).
How do I calculate a weighted mean in Excel?
Excel does not have a single "Weighted Average" function. You must use the =SUMPRODUCT() function to multiply values by their weights and then divide by the =SUM() of the weights.
Can I average cells that are not next to each other?
Yes. In the formula =AVERAGE(A1, C5, E10), use commas to separate individual cells or ranges that are not contiguous.
What is the difference between AVERAGE and MEDIAN?
The mean (AVERAGE) is the sum of all numbers divided by the count. The MEDIAN is the middle value of the dataset when sorted. Use MEDIAN if your data has extreme outliers that skew the average.
Will the mean update automatically if I change a number?
Yes. Excel formulas are dynamic. As soon as you change a value within the selected range and press Enter, the mean will update instantly.