ThisCalculator

Statistics

Expected Value Standard Deviation Calculator

Updated · Standard formula, shown below

The calculator for this page is switched off while it is checked. The formula is below, and the worked example in the article shows how to use it by hand.

Expected Value Standard Deviation Calculator

This calculator computes the expected value (mean) and standard deviation of a discrete probability distribution. You enter the possible outcomes and their probabilities, and it returns the mean, variance, and standard deviation, helping you quantify the center and spread of a random variable.

Formula

The expected value (also called the mean) of a discrete random variable is the probability-weighted average of all possible outcomes. It is calculated as:

μ = Σ [xᵢ · P(xᵢ)]

Where:

  • xáµ¢ = each possible outcome value
  • P(xáµ¢) = the probability of that outcome (must be between 0 and 1, and all probabilities must sum to 1)

The variance measures the average squared deviation from the mean:

σ² = Σ [P(xᵢ) · (xᵢ − μ)²]

The standard deviation is the square root of the variance:

σ = √σ²

All values are unitless in the calculator; if your outcomes have units (e.g., dollars, meters), the expected value carries the same unit, and the standard deviation also carries the same unit (not squared).

Worked Example

Using the default inputs: outcomes 1, 2, 3, 4, 5 with probabilities 0.1, 0.2, 0.4, 0.2, 0.1.

  1. First, verify probabilities sum to 1: 0.1 + 0.2 + 0.4 + 0.2 + 0.1 = 1.0 ✓
  2. Compute expected value: (1×0.1) + (2×0.2) + (3×0.4) + (4×0.2) + (5×0.1) = 0.1 + 0.4 + 1.2 + 0.8 + 0.5 = 3.0
  3. Compute variance: 0.1×(1−3)² + 0.2×(2−3)² + 0.4×(3−3)² + 0.2×(4−3)² + 0.1×(5−3)² = 0.1×4 + 0.2×1 + 0.4×0 + 0.2×1 + 0.1×4 = 0.4 + 0.2 + 0 + 0.2 + 0.4 = 1.2
  4. Standard deviation = √1.2 ≈ 1.0954

The calculator shows: expected value = 3.0, variance = 1.2000, standard deviation = 1.0954 (rounded to 4 decimals).

When to Use This Calculator

Use this tool whenever you have a complete list of possible outcomes and their exact probabilities. Common applications include:

  • Analyzing games of chance (dice, cards, roulette) to find the average payout
  • Evaluating investment scenarios with discrete return probabilities
  • Quality control when defects occur with known rates
  • Any situation described by a probability mass function

The expected value tells you the long-run average if you repeated the experiment many times. The standard deviation tells you how much individual results typically deviate from that average. A small standard deviation means results cluster tightly around the mean; a large one means results are spread widely.

How to Read the Result

The expected value is not necessarily a possible outcome. For example, rolling a fair die has an expected value of 3.5, even though you can never roll a 3.5. It represents the average over many trials.

The standard deviation is in the same units as the outcomes. If your outcomes are dollars, the standard deviation is in dollars. A common rule of thumb for roughly bell-shaped distributions is that about 68% of outcomes fall within one standard deviation of the mean, 95% within two, and 99.7% within three (the empirical rule). However, this rule only applies to approximately normal distributions, not to all discrete distributions.

Common Mistakes and Pitfalls

  • Probabilities not summing to 1: The formula assumes ΣP(x) = 1. If your probabilities sum to less than 1, you may be missing an outcome. If they sum to more, you have an error.
  • Using percentages instead of decimals: Enter 0.1 for 10%, not 10. The calculator treats numbers as raw values.
  • Confusing sample vs. population: This calculator computes the population parameters (μ and σ) for a fully specified distribution. If you have observed data and want the sample standard deviation, use a different calculator that divides by n−1.
  • Mixing up variance and standard deviation: Variance is in squared units; standard deviation is in original units. Always report the standard deviation when describing spread.
  • Assuming symmetry: The expected value is not the midpoint unless the distribution is symmetric. For skewed distributions, the mean shifts toward the tail.

Limitations of the Formula

This calculator works only for discrete distributions with a finite number of outcomes. For continuous distributions (like normal or exponential), you need integral calculus or specialized calculators. Also, the expected value and standard deviation describe the distribution fully only if the distribution is normal; for other distributions, they are still useful summary statistics but do not capture all features like skewness or kurtosis.

Another limitation: the calculator does not check that probabilities are non-negative or sum to 1. You must input valid probabilities yourself. If you enter negative probabilities or a sum not equal to 1, the results will be mathematically meaningless.

Frequently Asked Questions

What is the difference between expected value and mean?

They are the same thing when the probabilities are equal. The expected value is a weighted mean where each outcome is weighted by its probability. When all probabilities are equal (e.g., a fair die), the expected value equals the simple arithmetic mean.

Can the expected value be negative?

Yes. If outcomes include negative numbers (like losses in a game), the expected value can be negative. For example, a lottery ticket with a 1% chance of winning $100 and a 99% chance of losing $1 has an expected value of 0.01×100 + 0.99×(−1) = 1 − 0.99 = $0.01, which is positive, but if the prize were smaller, it could be negative.

What does a standard deviation of zero mean?

It means there is no variability: every outcome is exactly the same. For instance, if you have outcomes 5, 5, 5 with any probabilities that sum to 1, the standard deviation is 0.

Should I use population or sample standard deviation?

Use the population standard deviation when your probabilities describe the entire distribution (like a game or a known process). Use the sample standard deviation when you have a random sample from a larger population and want to estimate the population’s spread. This calculator handles the population case only.

How do I convert probabilities from percentages?

Divide each percentage by 100. For example, 25% becomes 0.25. Ensure all converted probabilities sum to 1 (or 100% before conversion).

What if my outcomes are not equally likely?

That’s exactly what this calculator is for. You enter each outcome and its specific probability. The calculator weights each outcome accordingly, which is the core of expected value calculation.

Related

Formula used
in list | Outcomes (x) | 1, 2, 3, 4, 5
in list | Probabilities (p) | 0.1, 0.2, 0.4, 0.2, 0.1
out mean | Expected value (μ) | - | sum(x*p) | 2
out var | Variance (σ²) | - | sum(p*(x-mean)^2) | 4
out sd | Standard deviation (σ) | - | sqrt(var) | 4

Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work

Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.