Weighted Mean Calculator: Formula, Examples, and Guide
A weighted mean, also called a weighted average, gives some values more influence than others. Instead of adding every value and dividing by the number of entries, the calculation multiplies each value by its weight, adds the products, and divides by the total weight.
This calculator works with percentage weights, frequencies, course credits, quantities, portfolio allocations, survey counts, and other numeric weights. The weights do not have to add to 100. Dividing by their total automatically normalizes them, provided the total weight is not zero.
How to Use the Weighted Mean Calculator
- Enter each number in the Value field.
- Enter the corresponding importance, frequency, percentage, credit, or quantity in the Weight field.
- Add more rows when the data set contains more entries.
- Use labels such as “Final Exam,” “Class A,” or “Purchase 1” to make the breakdown easier to read.
- Press Calculate Weighted Mean. The calculator does not update the results until the button is pressed.
- Review the weighted products, total weight, percentage influence, and comparison with the arithmetic mean.
Weighted Mean Formula
In this formula, xᵢ is a value, wᵢ is its corresponding weight, and the sigma symbol means to add all terms. The weighted mean is the sum of the value-weight products divided by the sum of the weights. NIST describes the weighted mean with this same general structure and notes its use with frequency data.[1]
Step-by-step method
- Multiply every value by its matching weight.
- Add all weighted products.
- Add all weights.
- Divide the product total by the weight total.
A larger weight gives its value more influence over the final answer. If all weights are equal, the weighted mean is the same as the ordinary arithmetic mean.
Weighted Mean Example With Percentages
Assume a course grade contains homework worth 20%, a midterm worth 30%, and a final exam worth 50%. The scores are 80, 74, and 92.
| Assessment | Score | Weight | Score × Weight |
|---|---|---|---|
| Homework | 80 | 20 | 1,600 |
| Midterm | 74 | 30 | 2,220 |
| Final exam | 92 | 50 | 4,600 |
| Total | 100 | 8,420 |
The ordinary mean of 80, 74, and 92 is 82. The weighted mean is higher because the strongest score, 92, carries the largest weight.
Do Weights Have to Add to 100?
No. Percentage weights often add to 100, but frequency counts, credit hours, and quantities usually do not. The formula divides by the total weight, so proportional weights produce the same answer.
For example, weights of 2, 3, and 5 have the same proportions as 20, 30, and 50. Multiplying every weight by the same positive number changes the numerator and denominator by the same factor, leaving the weighted mean unchanged.
Weighted Mean vs. Arithmetic Mean
An arithmetic mean treats every observation equally:
A weighted mean uses unequal influence. Use an arithmetic mean when every observation represents the same amount or importance. Use a weighted mean when values represent different frequencies, quantities, credits, probabilities, allocations, or levels of importance.
| Feature | Arithmetic mean | Weighted mean |
|---|---|---|
| Influence of each value | Equal | Set by its weight |
| Uses a separate weight column | No | Yes |
| Best for | Equivalent observations | Unequal importance or frequency |
| Same result when | All weights are equal | |
Weighted Mean With Frequencies
A frequency-weighted mean is useful when one value occurs several times. Instead of listing the same value repeatedly, enter the value once and use its frequency as the weight. NIST specifically identifies frequency data as a common application of weighted means.[1]
Suppose a survey records rating 3 from 10 people, rating 4 from 25 people, and rating 5 from 15 people:
The weighted mean rating is 4.1. A simple mean of 3, 4, and 5 would be 4.0 and would incorrectly treat each rating as if it occurred equally often.
Weighted GPA and Grade Calculations
Course credits can act as weights when calculating a grade-point average. Multiply each course grade point by its credit hours, add the products, and divide by total credits. A four-credit course influences the result twice as much as a two-credit course.
Within one course, syllabus percentages can serve as weights for homework, quizzes, projects, exams, and participation. If the categories have different importance, adding category scores and dividing by the number of categories gives the wrong result. Use the Grade Calculator when the calculation also needs points, assignments, or a target final grade.
Weighted Average Cost and Investment Examples
Weighted means are also useful for average purchase cost. If an investor buys 10 units at $20 and 30 units at $25, the correct average cost is weighted by quantity:
The simple average of $20 and $25 is $22.50, but that ignores the fact that three times as many units were bought at $25. Transaction fees, taxes, and lot-specific accounting can require additional calculations.
Portfolio return can also use allocation percentages as weights. If allocations do not remain constant throughout the period, a single weighted mean may not capture contributions, withdrawals, or changing exposure. Use the ROI Calculator for a broader investment-return estimate.
Normalized Weights
Normalized weights add to 1. Divide each original weight by the total weight to normalize it:
A weight of 30 in a total of 100 has a normalized weight of 0.30. A weight of 3 in a total of 10 also normalizes to 0.30. The calculator reports each row’s influence as a percentage of total weight, which is the normalized weight multiplied by 100.
Can Weights Be Zero or Negative?
A zero weight is valid in ordinary weighted-mean arithmetic, but that row has no effect on the result. All weights cannot be zero because the formula would require division by zero.
Most practical weighted means use nonnegative weights. Negative weights can occur in specialized mathematical, statistical, or financial methods, but they may place the result outside the range of the entered values and can be difficult to interpret. This calculator blocks negative weights by default. Enable them only when the chosen method specifically requires them.
Common Weighted Mean Mistakes
- Dividing by the number of values: Divide by the sum of weights, not the row count.
- Using mismatched rows: Every value must be paired with its intended weight.
- Averaging percentages with unequal bases: Weight rates by the correct counts or denominators.
- Forgetting course credits or quantities: A simple mean can misstate the result when amounts differ.
- Mixing weight formats: Do not combine 25% as 25 with another percentage entered as 0.50 unless that difference is intentional.
- Using a zero total weight: The weighted mean is undefined when the denominator is zero.
- Assuming weights must equal 100: Any proportional scale works.
- Rounding each intermediate product: Keep full precision until the final result when accuracy matters.
Frequently Asked Questions
How do you calculate a weighted mean?
Multiply each value by its corresponding weight, add the products, add the weights, and divide the product total by the weight total.
What is the weighted mean formula?
The formula is Σ(value × weight) ÷ Σ(weight).
Is weighted mean the same as weighted average?
Yes. The terms weighted mean and weighted average are commonly used for the same calculation.
Do weights have to add to 100?
No. Weights can be percentages, frequencies, quantities, credits, or other proportional values. The formula divides by their total.
What happens if all weights are equal?
The weighted mean becomes the same as the ordinary arithmetic mean.
Can a weight be zero?
Yes. A zero-weight row contributes nothing, but the total of all weights must not be zero.
Can weights be negative?
Negative weights are used in some specialized methods, but most everyday weighted means use nonnegative weights. This calculator requires users to enable negative weights explicitly.
How is a weighted GPA calculated?
Multiply each course grade point by its credit hours, add the products, and divide by total credit hours.