Statistics & probability

Discrete expected value and variance calculator

Build a finite probability distribution and inspect each outcome’s exact contribution to its expected value.

Your numbers

Up to 100 rows. Use bounded integers, decimals with at most six places or fractions such as 1/3. Probabilities must add to exactly 1; they are not automatically normalized.

Calculated on your device. Your inputs aren’t sent to us.

Your result

Ready when you are

Enter your inputs and select Calculate.

Try it, understand it

Explore the result

Keep outcomes aligned with probabilities and inspect the exact contribution table.

Worked example comparison
ExampleOutputWhat to notice
A mean between outcomesExpected value1.1The expectation is 1.1 even though only 0, 1 and 2 can occur.
Three equally likely valuesExpected value2Exact thirds sum to one and give mean two.
A signed payoffExpected value0A possible loss and gain can balance to a zero mean.

Check your understanding

Is a mean of 1.1 an additional possible outcome?

No. A mean summarizes the model; it need not be in the outcome list.

Does the model include sample-variance correction?

No. It computes the variance of the supplied distribution.

Behind the numbers

How this calculation works

Match every outcome with its probability before multiplying. The expectation adds those weighted contributions. Variance instead adds probability-weighted squared distances from that mean. The table retains the supplied rows; the plot combines rows with the same numerical outcome. Exact rational checks distinguish a complete probability model from arbitrary weights.

THE FORMULAE[X] = Σ xᵢpᵢ; Var(X) = Σ pᵢ(xᵢ−E[X])²

A worked example

For outcomes 0, 1 and 2 with probabilities 0.2, 0.5 and 0.3, the expected value is 0×0.2+1×0.5+2×0.3 = 1.1. The exact variance is 0.49 and standard deviation is 0.7.

Good to know

A finite discrete distribution only, with 1–100 rows and probabilities from 0 to 1 summing exactly to 1. Decimal entry allows six places; use fractions for recurring probabilities. Outcome magnitudes and fraction denominators are bounded to 1,000,000. A large exact intermediate expression can reach the arithmetic size limit. No empirical fit, continuous density integration or guaranteed next outcome.

The average can be a value that never occurs

A distribution with possible outcomes zero, one and two can have expectation 1.1 even though 1.1 is not one of its outcomes. Expectation describes the probability-weighted balance point of the model. It does not announce the result of the next trial or require a decimal outcome to become possible.

The weighted average calculator accepts general nonnegative weights and normalizes their sum. This expected-value tool deliberately asks for probabilities that already form a complete distribution. That distinction prevents a forgotten outcome or a probability entered as 20 instead of 0.2 from being silently reinterpreted.

A row with zero probability makes no contribution to the expectation or variance. Rows with the same payoff can be kept separate when they represent different events; the plot combines their probabilities at that payoff. Negative outcome values are allowed because outcomes can represent losses or signed changes, while probabilities themselves remain nonnegative.

Probability bookkeeping comes before multiplication

The exact probability sum must be one. Three decimal entries of 0.333333 sum to 0.999999, not exactly one; use 1/3 for an intended equal three-way distribution. This preserves the difference between an exact model and rounded estimates. If the input consists of observed frequencies instead, turn them into the intended probability model first.

Variance uses squared distances from the expectation, weighted by the same probabilities. It is a property of the entered distribution and is not the sample-variance calculation that divides deviations by n−1. The statistics calculator handles unweighted observations with an explicit sample or population convention.

The long-run interpretation needs repeated trials from the stated model. A favorable expected payoff does not establish affordability, a safe strategy or the probability of avoiding a loss over a short run. Inspect the outcome table and spread as well as the mean.

A few questions, answered

Must the expected value be a possible outcome?

No. A weighted mean can fall between outcomes, such as 1.1 for outcomes 0, 1 and 2.

Why reject probabilities that nearly add to one?

The tool checks the supplied rational model exactly rather than guessing a normalization. Use exact fractions when equal recurring probabilities are intended.

Are repeated outcome values allowed?

Yes. Their row contributions are retained and their probabilities combine in the plot.

Find your calculator

Start typing to explore the library.