Expected Value Calculator: Mean, Variance & Break-Even

Expected value tells you what one round of a repeated choice is worth on average. It says nothing certain about any single round, and the gap between the two can be wide. Two players each bet $1 a spin for 1,000 spins of an American roulette wheel. One always bets red; the other always bets a single number. Both bets have the same expected value, −$0.0526 a spin, so both players expect to be down $52.63. Yet after the 1,000 spins the single-number player is ahead 39.6% of the time and the red player only 4.5% of the time.

This calculator gives the expected value, variance and standard deviation of any table of outcomes, with exact fractions when you type fractions. It also handles a cost to play, a simple win-or-lose bet with its break-even chance, the chance of ending ahead after any number of plays, and a side-by-side comparison of two options. It opens on the single-number bet from the example.

Expected Value Calculator

Probabilities can be 0.25, 25% or 1/4. Write “rest” for one of them to fill the gap to 1. Losses are negative. Leave out thousands commas (type 1000, not 1,000).

Expected value –
Outcomes on a number line (bar height = probability)
Step by step
    Outcome table

    Three Tabs for Three Kinds of Question

    Your questionTabWhat you type
    What is this table of outcomes worth on average, and how much does it swing?Outcome tableOutcomes in one box, their probabilities (or counts) in the other, in the same order
    Is this bet or offer worth taking, and at what chance does it break even?Win or loseChance of winning, profit if you win, amount lost if you lose
    Which of two options is better on average, and how often does each one come out on top?Compare two optionsAn outcome list and a probability list for each option

    A few input rules apply to every tab. A probability can be a decimal (0.25), a percentage (25%) or a fraction (1/4). In the outcome table you can write “rest” for one probability, and the calculator fills in whatever is needed to reach 1. If you have counts from a survey or a log instead of probabilities, switch the second box to “counts or weights”. Losses are typed as negative numbers in the table tabs.

    Two optional boxes widen the outcome table. Cost to play subtracts a fixed price from every outcome, which turns prize amounts into net results and adds a fair price and the share kept by the other side. Number of plays adds the expected total, its spread, and the chances of ending ahead, behind or exactly even after that many independent plays.

    A Weighted Average, Not a Likely Result

    The formula multiplies each outcome by its probability and adds the products:

    E(X) = x₁ × p₁ + x₂ × p₂ + … + xₖ × pₖ

    Suppose a small bakery takes orders for a custom cake that must be made the day before. From its records, daily orders for this cake run like this:

    Orders in a day x0123
    Probability p0.200.350.300.15
    x × p00.350.600.45

    E(X) = 0 + 0.35 + 0.60 + 0.45 = 1.4 cakes a day.

    No day ever brings 1.4 orders. The expected value is the long-run average: over 100 days the bakery should see about 140 orders in total. Picture the four bars of the table on a number line, with heights equal to the probabilities. The expected value is the point where that line would balance on a finger. The calculator’s chart marks this balance point in orange, which helps when outcomes sit far apart: in the roulette chart, the small bar at 35 pulls the balance point almost all the way back up to zero.

    The probabilities have to add up to exactly 1, because together they cover everything that can happen. If they add to 0.95, an outcome is missing; if they add to 1.05, something is counted twice. The calculator stops and names the gap in both cases. When the total misses 1 only by rounding (three values of 0.333, for example), it scales them to add to 1 and says so.

    Variance and Standard Deviation: How Far Results Wander

    The expected value is the centre. The variance measures the spread around it, as the average squared distance from E(X):

    σ² = Σ p × (x − E)², or the shortcut σ² = E(X²) − E(X)².

    For the cakes, E(X²) = 0² × 0.20 + 1² × 0.35 + 2² × 0.30 + 3² × 0.15 = 2.9, so σ² = 2.9 − 1.4² = 0.94 and the standard deviation σ = √0.94 = 0.97 cakes. The step list shows both E(X) and E(X²), and the table adds each outcome’s share of the variance, so you can see which outcomes create the swing.

    Two rules come up whenever outcomes are changed by a fixed rule:

    • Adding a constant shifts the expected value by that constant and leaves the variance alone. A $4 entry fee lowers every result by $4, lowers E by $4, and changes nothing about the spread. That is why the calculator’s “cost to play” box moves the expected value but keeps the SD.
    • Multiplying by a constant multiplies E by it and the variance by its square. Betting $10 instead of $1 multiplies the expected loss by 10 and the standard deviation by 10, while the variance grows by 100.

    A rule known as Chebyshev’s inequality puts a floor under how much probability sits near the expected value, whatever the shape of the table: at least 75% lies within 2 SDs of E, and at least 88.9% within 3 SDs. For the cakes, 2 SDs either side of 1.4 runs from −0.54 to 3.34, which covers every outcome. The rule is loose, but it holds for any distribution, even one with a long tail on one side.

    The variance has squared units (dollars squared, cakes squared), which is why the SD is easier to read. The standard deviation calculator does the same job for a list of observed values rather than a table of probabilities.

    Same Expected Value, Very Different Ride

    Back to the roulette wheel from the start. An American wheel has 38 pockets: 1 to 36, plus 0 and 00. A single-number bet pays 35 to 1 and a red bet pays even money. Per $1:

    BetWinChanceE per $1SD per $1
    Single number+$351/38−1/19 ≈ −$0.0526$5.76
    Red+$118/38−1/19 ≈ −$0.0526$1.00

    The expected values are identical; the standard deviations differ by almost six times. Over n spins, the expected total grows with n while the spread of the total grows with √n. That is the whole story of the next table, which shows the chance of being ahead after n spins of $1:

    SpinsExpected totalSingle number: chance aheadRed: chance ahead
    10−$0.5323.4%31.4%
    100−$5.2649.2%26.5%
    1,000−$52.6339.6%4.5%
    10,000−$526.3218.5%0.0000066%

    The red bettor’s chances fall steadily: the expected loss after 1,000 spins ($52.63) is already 1.7 standard deviations ($31.58) below zero. The single-number bettor’s results swing so widely ($182.23 SD after 1,000 spins) that the expected loss stays hidden for a long time. The jump from 10 to 100 spins comes from how the payouts line up: after 100 spins, three wins out of 100 already put a single-number player ahead.

    This is the “Number of plays” box at work. For bets with two outcomes the calculator uses the exact binomial distribution for any number of plays. For tables with more outcomes it adds up the exact distribution of the total while that stays manageable, and switches to a normal approximation (marked “≈”) beyond that. The binomial distribution calculator shows the win counts behind the two-outcome case.

    Fair Price and the Share Kept by the House

    A game is fair when the cost to play equals the expected payout, so the net expected value is zero. Anything above that price is kept by whoever runs the game, on average.

    Every bet on an American wheel except one has the same net expected value, −1/19 per $1, a loss of 5.26%. The exception is the five-number bet on 0, 00, 1, 2 and 3, which pays 6 to 1:

    E = 6 × 5/38 − 1 × 33/38 = −3/38 ≈ −$0.0789, a loss of 7.89% per $1.

    On a single-zero wheel with 37 pockets, the single-number bet becomes 35 × 1/37 − 36/37 = −1/37, a loss of 2.70%. Removing one pocket roughly halves the expected loss without changing any payout. Game makers state the same idea as the return to player: the expected payout as a share of what is staked. That is 94.74% for any standard American-wheel bet (100% − 5.26%) and 97.30% for a single-zero wheel.

    The cost box handles games described by their prizes. Type the prize amounts as outcomes and the price as the cost. For example, a game that charges $4 to roll one die and pays the number rolled in dollars returns 3.5 on average. The calculator then shows a net expected value of −$0.50, a fair price of $3.50, and 12.5% of every $4 kept by the game over time.

    Break-Even Chance for a Win-or-Lose Choice

    When a choice has only two results, there is a single chance at which it neither gains nor loses on average:

    Break-even chance = loss ÷ (profit + loss)

    Say preparing a bid for a contract costs $300 in time and fees, and winning it would bring $2,000 of profit. The break-even chance is 300 ÷ 2,300 = 3/23 ≈ 13.0%. If your honest estimate of winning is 20%, the bid is worth 0.2 × 2,000 − 0.8 × 300 = +$160 on average. If you win only one bid in eight (12.5%), it loses $12.50 on average.

    The Win or lose tab gives this break-even chance next to your expected value. It also shows the fair profit at your chance, which is the payout that would make the bet exactly even, and the return per 1 risked, the expected value as a share of what you put at stake. For a $1 red bet in roulette the break-even chance is 50%; the real chance is 18/38 = 47.4%. That shortfall of 2.6 percentage points, doubled by the even-money payout, is the 5.26% expected loss.

    Guessing on a Test That Takes Points Off for Wrong Answers

    Some multiple-choice tests award 1 point for a right answer and take a quarter point off for a wrong one, with five choices per question. Whether a guess is worth making is an expected value question, and the answer depends on how many choices you can rule out first:

    Choices leftChance rightE of a guess (points)
    51/51/5 − 4/5 × 1/4 = 0
    41/41/4 − 3/4 × 1/4 = 1/16
    31/31/3 − 2/3 × 1/4 = 1/6
    21/21/2 − 1/2 × 1/4 = 3/8

    The quarter-point penalty is set so that a blind guess among five choices is worth exactly zero on average. Rule out even one wrong choice and the guess turns positive. On 20 questions where you can rule out two choices each, guessing adds 20 × 1/6 = 10/3 ≈ 3.3 points on average.

    To check a row, open the Win or lose tab with the chance as a fraction, a profit of 1 and a loss of 0.25. The answer comes back as an exact fraction, and adding 20 plays shows how often the guesses would still leave you behind. If a test gives no penalty for wrong answers, every guess has a positive expected value and leaving a question blank is never better. For the chance of passing a whole test by guessing, rather than the points one guess is worth, use the probability calculator.

    Reading Odds as Win-or-Lose Numbers

    Payouts are written in different ways, and each one converts to the profit-and-loss form the Win or lose tab uses:

    • “35 to 1” or 35/1 means a profit of 35 for each 1 staked, plus the stake back. Profit 35, loss 1.
    • Decimal odds of 3.0 include the stake: a $1 bet returns $3 in total, so the profit is $2 and the loss is $1.
    • “Odds against” of 4 to 1 describes a chance, not a payout: 4 ways to lose for every 1 way to win, so the chance is 1/5.

    The break-even chance for any payout is loss ÷ (profit + loss); for decimal odds it simplifies to 1 ÷ decimal odds, so 3.0 breaks even at 33.3%. A bet is worth taking on average only when your honest estimate of the chance is above that figure. At decimal odds of 3.0 with a true chance of 30%, E = 0.3 × 2 − 0.7 × 1 = −$0.10 per $1, a loss even though the payout looks generous. On a roulette wheel every payout is set below the fair one: a single number would need to pay 37 to 1 to break even on 38 pockets, not 35 to 1, and that shortfall is the house’s margin.

    How Many Cakes to Bake: Expected Value as a Decision Rule

    Back at the bakery, each cake costs $12 to make and sells for $30. Unsold cakes can’t be sold the next day. Using the order table from earlier, here is the expected profit for each choice of how many to bake:

    Cakes bakedProfit if 0 / 1 / 2 / 3 ordersExpected profitSDChance of a loss
    0$0 / $0 / $0 / $0$0$00%
    1−$12 / $18 / $18 / $18$12.00$12.0020%
    2−$24 / $6 / $36 / $36$13.50$22.9920%
    3−$36 / −$6 / $24 / $54$6.00$29.0955%

    Baking two cakes gives the highest expected profit, even though it loses money on one day in five. Baking three, the most cakes anyone could sell, wins big on the best days but drops the average to $6 and loses money more often than not. Each row is one run of the Outcome table tab: type the four profits as outcomes and 0.2, 0.35, 0.3, 0.15 as probabilities.

    The method is general. List the choices, find the outcomes and their chances for each, and compare the expected values. Then look at the SD and the chance of a loss before deciding, because the next section shows the highest average is not automatically the right pick.

    When the Higher Expected Value Isn’t the Safer Choice

    An event organiser picks between an outdoor site and a hall. Outdoors brings $6,000 of profit if the day is dry and a $1,500 loss if it rains; the forecast gives a 70% chance of a dry day. The hall brings a steady $3,200 either way.

    • Outdoors: E = 0.7 × 6,000 + 0.3 × (−1,500) = $3,750, SD $3,436.93, a loss 30% of the time.
    • Hall: E = $3,200, SD $0, never a loss.

    The Compare two options tab shows that the outdoor site wins by $550 on average and beats the hall 70% of the time. It also flags the price of that extra $550: a 30% chance of losing $1,500. An organiser who runs dozens of events a year can take the average and let good and bad days even out. One who would be in trouble after a single loss may reasonably prefer the hall.

    The same numbers show what a perfect weather forecast would be worth. With a forecast you’d pick outdoors on dry days and the hall on wet ones: 0.7 × 6,000 + 0.3 × 3,200 = $5,160 on average. That is $1,410 more than the best choice made without a forecast. This figure is called the expected value of perfect information, and it caps what any forecast or survey could be worth for this decision.

    Insurance and Warranties: Paying More Than the Expected Loss

    Suppose a two-year protection plan for a phone costs $150. Say there is a 20% chance of a $400 repair and a 5% chance of a $900 replacement in that time, with no other claims. The expected cost without the plan is 0.20 × 400 + 0.05 × 900 = $125, so the plan costs $25 more than the loss it covers, on average.

    That gap is how insurance pays its costs and profits, and it is why buying cover has a negative expected value for the buyer. It can still be a sound choice. Expected value treats losing $900 once as no worse than losing $90 ten times, and for someone without savings it is worse. A practical rule follows from this: insure losses you couldn’t absorb, and cover the small ones yourself, where paying above the expected loss buys little. To run your own version, put the plan price into the comparison as a sure −150 and the uncovered costs as the other option.

    Adding Expected Values Without Building the Whole Table

    The expected value of a sum is the sum of the expected values: E(X + Y) = E(X) + E(Y). This holds even when X and Y depend on each other, and it can turn a hard question into an easy one.

    • Shared birthdays. In a group of 23 people there are 253 pairs. Each pair shares a birthday with chance 1/365 (ignoring leap days). The expected number of shared-birthday pairs is 253/365 ≈ 0.69, found without listing a single group.
    • Random matches. If n letters go into n addressed envelopes at random, each letter lands in its own envelope with chance 1/n. Adding n of those gives an expected 1 correct match, whether there are 5 letters or 5,000.
    • Several plays. The expected total of n plays is n × E, which is the first line of the calculator’s “plays” output.
    • Collecting a full set. A cereal brand hides one of 6 toys in each box, all equally likely. Once you hold k different toys, a new one turns up with chance (6 − k)/6, so the wait for it averages 6/(6 − k) boxes (the geometric shortcut below). Adding the six waits gives 6 × (1 + 1/2 + 1/3 + 1/4 + 1/5 + 1/6) = 14.7 boxes on average for the whole set, and more than half of that wait goes on the last two toys.

    Variances add only when the parts are independent: Var(X + Y) = Var(X) + Var(Y) needs independence, or an extra covariance term. That is why the calculator’s spread for n plays, σ × √n, assumes each play is independent of the others.

    Shortcuts for Named Distributions

    Some distributions have expected values in closed form, so you don’t need the table:

    DistributionWhat it countsE(X)Example
    Binomialsuccesses in n tries with chance pn × p50 calls at 12% → 6 sales
    Geometrictries until the first success1 ÷ pp = 1/6 → 6 tries on average
    Poissonevents in a fixed time, average rate λλ3.2 emails an hour → 3.2
    Discrete uniformwhole numbers a to b, equally likely(a + b) ÷ 2numbers 1 to 20 → 10.5
    Hypergeometricspecial items in n draws from N with K specialn × K ÷ N5 cards from 52, hearts → 1.25

    These match what the Outcome table tab gives when you type the full table, which is a handy check. For a geometric count, “tries until the first success” includes the successful try; counting only the failures before it gives (1 − p) ÷ p instead, so check which one a textbook means.

    Counts Instead of Probabilities

    Data from a survey or a log comes as counts. Thirty students reporting their number of siblings might give:

    Siblings01234
    Students612831

    Switch the second box to “counts or weights”, type 6, 12, 8, 3, 1, and the calculator divides each count by 30. The expected value, 41/30 ≈ 1.37 siblings, is the same as the mean of the 30 answers, which the mean, median and mode calculator also gives from a frequency table.

    One difference matters. The SD shown here is the population SD, 1.016, which treats the counts as the whole distribution. If the 30 students are a sample from a larger group and you want to estimate that group’s spread, the sample SD divides by 29 instead of 30 and gives 1.033. With a large sample the two barely differ.

    Where Expected Value Misleads

    • The probabilities are guesses. The bid example breaks even at 13.0%. If the real chance is 10% rather than 20%, the answer flips from +$160 to −$70. When probabilities are estimates, rerun the calculation with lower and higher values and see whether the decision changes.
    • One-off choices. The long-run average shows up only over many repetitions. For a decision you face once, the spread and the worst case deserve as much weight as E.
    • Rare, huge outcomes. A small chance of an enormous payout can dominate E. In the classic St. Petersburg game, a coin is tossed until heads appears; the prize starts at $2 and doubles with every toss. Each possible toss count adds $1 to the expected value, so the sum has no limit. Yet half of all games pay $2, and the chance of winning more than $20 is only 1 in 16.
    • Average versus typical. In the single-number roulette bet the most likely result of a spin is −$1, and the median result after 1,000 spins is a loss too, while the mean, −$0.0526 a spin, looks small and harmless. The calculator lists the most likely outcome and the chances of a gain and a loss for this reason.

    Expected Value in Excel and Google Sheets

    Put the outcomes in A2:A5 and the probabilities in B2:B5. Both spreadsheets use the same formulas:

    What you wantFormula
    Check the probabilities=SUM(B2:B5) (should be 1)
    Expected value=SUMPRODUCT(A2:A5, B2:B5)
    Variance (value of E in D1)=SUMPRODUCT(B2:B5, (A2:A5-D1)^2)
    Standard deviation=SQRT(SUMPRODUCT(B2:B5, (A2:A5-D1)^2))

    For the cake orders these give 1, 1.4, 0.94 and 0.9695. Avoid AVERAGE(A2:A5) for this job: it treats every outcome as equally likely and would give 1.5 cakes.

    Five Checks Before You Act on an Expected Value

    1. Do the probabilities add up to 1, and is every outcome listed? A missing outcome, like an unsold cake or a failed bid, changes the answer.
    2. Are the outcomes net or gross? Decide whether the stake or cost is already subtracted, and don’t subtract it twice. Use the cost box only when the outcomes are prizes before the cost.
    3. How large is the SD compared with E? A small expected gain with a large SD needs many repetitions to show up, as the roulette table shows.
    4. Can you survive the worst outcome? If not, a lower expected value with a better worst case may be the sensible choice.
    5. How sure are the probabilities? Try the calculation with the low and high ends of your estimates. If the decision holds at both, act on it with more confidence.