Weighted Standard Deviation Calculator
Enter values and matching weights to find the weighted standard deviation.
Result
How it is calculated
You enter a list of values xi and a list of weights wi of the same length, separated by commas or spaces. The weighted mean is x̄w = Σ wixi ÷ Σ wi. The weighted standard deviation is the sample form of NIST's Dataplot manual: sw = √( Σ wi(xi − x̄w)² ÷ ((N′ − 1) × Σ wi ÷ N′) ), where N′ is the number of non-zero weights. The population form, √( Σ wi(xi − x̄w)² ÷ Σ wi ) (OpenStax's standard deviation with frequencies), is shown beside it, labeled. With fewer than two non-zero weights the sample form is not defined. The two lists must have equal length, no weight may be negative, and the weights must add up to more than zero; otherwise there is no result. A weight of 0 simply removes that value from the calculation, and with all weights equal the two forms are the ordinary sample and population standard deviations.
Worked example
Values 70, 80, 90 with weights 1, 2, 3. The weights add up to 6. Weighted mean: (1×70 + 2×80 + 3×90) ÷ 6 = 500 ÷ 6 = 83.33. Deviations squared and weighted: 1×(70 − 83.33)² = 177.78, 2×(80 − 83.33)² = 22.22, 3×(90 − 83.33)² = 133.33, total 333.33. All three weights are non-zero, so N′ = 3 and NIST's sample form divides by (N′ − 1) × Σw ÷ N′ = 2 × 6 ÷ 3 = 4: √(333.33 ÷ 4) = √83.33 = 9.13. Result: weighted standard deviation 9.13 around a weighted mean of 83.33. The population form divides by the sum of the weights: √(333.33 ÷ 6) = √55.56 = 7.45.
Common mistakes
- Giving a different number of weights than values. Every value needs exactly one weight, and a mismatch returns no result.
- Using percentages and expecting them to matter. Weights of 10, 20, 30 and 1, 2, 3 give the same answer, because only the ratios between weights count.
- Comparing with the wrong form. The main figure is NIST's sample form; a reference that divides by the sum of the weights matches the population form shown beside it.
- Entering a negative weight to mean less trust. A weight must be zero or positive; a negative one is rejected and shows no result, as do weights that are all zero.
- Separating numbers with a decimal comma, such as 2,5, inside the list. The comma separates items, so write 2.5 for a decimal.
Sources
- 2.7 Measures of the Spread of the Data (population standard deviation with frequencies, σ = √(Σf(x − μ)²/N)) - Introductory Statistics 2e — OpenStax, Introductory Statistics 2e
- WEIGHTED STANDARD DEVIATION (Dataplot Reference Manual, Eq. 2-22: Σwᵢ(xᵢ − x̄w)² ÷ ((N′ − 1)Σwᵢ/N′), N′ the number of non-zero weights) — NIST Information Technology Laboratory, Statistical Engineering Division
About this calculator
The weighted standard deviation measures spread around a weighted mean rather than a plain average, giving each data point influence in proportion to a weight you assign it, a reliability score, sample size, or measurement precision, instead of treating every value as equally trustworthy.
This matters whenever the data points being combined aren't equally reliable: meta-analyses in research combine results from studies of different sizes by weighting larger, more precise studies more heavily; survey analysts weight responses to correct for over- or under-sampled demographic groups; and lab scientists combine repeated measurements with different precisions using weights based on their measurement uncertainty. Using an unweighted standard deviation in these cases would let noisy or unreliable data points distort the result just as much as trustworthy ones.
Was this helpful?
You can pick up to 3 reactions.
Popular calculators
Loan Calculator
Monthly payment, total interest and full amortization schedule.
Percentage Calculator
Percent change, percent of, and ratio calculations.
Discount Calculator
Calculate final price, savings, and discount amount.
BMI Calculator
Body mass index from height and weight (metric or imperial).
Age Calculator
Compute your exact age in years, months and days from a birth date.
Compound Interest Calculator
Calculate the final amount and interest earned with compounding.
All Calculators
- Loan Calculator
- Profit Calculator
- Discount Calculator
- BMI Calculator
- Percentage Calculator
- Ideal Weight Calculator
- Age Calculator
- Pregnancy Due Date Calculator
- Compound Interest Calculator
- BMR Calculator (Basal Metabolic Rate)
- Tip Calculator
- Fuel Cost Calculator
- Date Difference Calculator
- Sleep Cycle Calculator
- Daily Water Intake Calculator
- Simple Interest Calculator
- Heart Rate Zones Calculator
- Running Pace Calculator
- Pet Age Calculator
- Calories Burned Calculator
- Macro Calculator
- TDEE Calculator (Total Daily Energy Expenditure)
- Waist-to-Hip Ratio Calculator
- Honor Roll Calculator
- One Rep Max (1RM) Calculator
- Ovulation Calculator
- Electricity Cost Calculator
- Unit Price Calculator
- Savings Goal Calculator
- Break-Even Point Calculator
- Paint Calculator
- Course Grade Average Calculator
- Business Days Calculator
- Time Duration Calculator
- Fuel Economy Calculator
- Temperature Converter
- Tile Calculator
- Aspect Ratio Calculator
- Roman Numeral Converter
- Goal Weight Timeline Calculator
- Salary Converter (Hourly to Annual)
- Credit Card Validator (Luhn)
- Body Surface Area (BSA) Calculator
- Feels-Like Temperature Calculator
- Ohm's Law Calculator
- PPI (Pixel Density) Calculator
- Molar Mass Calculator
- Zodiac Sign Calculator (Western + Chinese)
- IBAN Validator
- Shoe Size Converter
- Country Info & Dialing Code Lookup
- Time Zone Difference (World Clock)
- CAGR (Compound Annual Growth Rate) Calculator
- Rule of 72 Calculator
- Blood Alcohol Content (BAC) Calculator
- Lean Body Mass (LBM) Calculator
- Pythagorean Theorem Calculator
- Speed Converter
- Download Time Calculator
- Date Calculator (Add/Subtract)
No calculators found
Comments