# Weighted average calculator > How do you find a weighted average? Values and their weights give the weighted mean, each row's share and contribution, shown as the point where a beam balances. Paste values and weights for the weighted average of grades, credits or a portfolio, with each row's share and contribution and the balance point drawn. - Page: https://how.box/weighted-average/ - Runs entirely in the browser. - License: HowToolbox's own text and data (titles, explanations, FAQs, tool descriptions and schemas, this file) are CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/); AI training and answers are welcome. Attribute "HowToolbox (how.box)" with a link to the page used. Third-party data keeps its own terms; the name and logo are not licensed. Publisher: HowToolbox, contact@how.box. Terms: https://how.box/about/terms/ ## Inputs Answer link: https://how.box/weighted-average/?v={v}&w={w} - `v` (text): The values, separated by spaces, line breaks or semicolons. Example: `85 92 78`. - `w` (text): One weight per value, in the same order. Example: `30 50 20`. Example answer: https://how.box/weighted-average/?v=85+92+78&w=30+50+20 A complete link carries the primary answer in the page HTML; a missing or invalid value shows the default page. ## Agent tools - `weighted_average_calculate`: Weighted average (weighted mean) Σ wᵢxᵢ ÷ Σ wᵢ of values paired with weights by position, e.g. - MCP, one POST to https://how.box/mcp: `{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"weighted_average_calculate","arguments":{"values":"85 92 78","weights":"30 50 20"}}}` - GET: https://how.box/mcp/run/weighted_average_calculate?values=85+92+78&weights=30+50+20 ## How it works A weighted average lets some values count more than others. Multiply each value by its weight, add the products up, and divide by the total weight: x̄w = Σ wᵢxᵢ ÷ Σ wᵢ, where xᵢ are the values and wᵢ their weights. When every weight is the same, it is the ordinary mean. Example: a course grade is homework 85 (weight 30 %), exams 92 (50 %) and a project 78 (20 %). The products are 25.5 + 46 + 15.6 = 87.1, and the weights add up to 100, so the weighted average is 87.1, above the plain mean of 85 because the strong exam result carries half the weight. Each product divided by the total weight is that row's contribution; the contributions add up to the answer. Think of the values as blocks on a beam, each as heavy as its weight: the weighted average is where the beam balances, its centre of mass. Weights can be any non-negative numbers and need not add up to 100; only their proportions matter. For a grade point average, check your school's own rules, such as which courses count and how grades are rounded. Definitions follow the NIST/SEMATECH e-Handbook of Statistical Methods. ## FAQ **Can I combine averages for groups of different sizes?** Yes, if they measure the same quantity. Enter each group’s average as the value and its number of observations as the weight. **How do I calculate a GPA with credits?** Enter each course's grade as a value and its credits as the weight. The weighted average is the credit-weighted grade point average. **Does changing every weight by the same factor change the answer?** No. Doubling all the weights doubles both the weighted sum and the total weight, leaving their ratio unchanged. **Can I use it for a portfolio’s average return?** For holdings measured over the same period, use each return as a value and its starting amount invested as the weight. This simple calculation does not account for money added or withdrawn during the period. **What happens if a weight is zero or negative?** A zero weight makes that value contribute nothing to the weighted average. Negative weights are left out and flagged; if all weights are zero, there is no weighted average. More: [HowToolbox index](https://how.box/llms.txt) · [Agent Skill](https://how.box/skill.md) · [agent terms](https://how.box/about/agents/)