DEV Community

Cover image for Expected Value Is a Function, Not a Prediction
E. Mitev
E. Mitev

Posted on

Expected Value Is a Function, Not a Prediction

Expected value is often presented as a betting concept, but the underlying idea should feel familiar to anyone who works with data.

You define every possible result, assign a probability to each one, and calculate the probability-weighted average.

In other words, expected value is an aggregation function:

EV = Σ probability(outcome) × net_result(outcome)
Enter fullscreen mode Exit fullscreen mode

The formula is simple. The difficult part is deciding whether the probabilities and prices supplied to it deserve to be trusted.

This article explains how expected value works, how to calculate it, and why a positive result is not a prediction about the next event.

Disclosure: This article was prepared with AI-assisted editing and reviewed for mathematical consistency. The examples are educational and should be verified independently.

Expected value measures decisions, not individual outcomes

Suppose you are evaluating a bet with two possible results:

  • It wins and produces a net profit.
  • It loses and the stake is lost.

A winning bet is not automatically a good decision. A losing bet is not automatically a bad one.

The quality of the decision depends on the relationship between:

  1. the probability of winning;
  2. the price being offered;
  3. the amount that can be gained or lost.

Expected value combines those inputs into a single long-run average.

It answers this question:

If the probability estimate is accurate and the same decision is repeated many times, what average net result does the price imply?

It does not answer:

Will the next bet win?

That distinction is the foundation of EV analysis.

The compact formula for decimal odds

For a one-unit stake, define:

  • p as the estimated probability of winning;
  • O as the decimal odds.

The expected net value is:

EV = (p × O) - 1
Enter fullscreen mode Exit fullscreen mode

Multiply the result by 100 to express it as a percentage of the stake.

Assume:

Estimated probability = 55% = 0.55
Decimal odds = 2.00
Enter fullscreen mode Exit fullscreen mode

Then:

EV = (0.55 × 2.00) - 1
EV = 0.10
EV = +10%
Enter fullscreen mode Exit fullscreen mode

This does not mean the next bet will return 10%.

With a one-unit stake at odds of 2.00, the actual net result is either:

  • +1 unit if the bet wins;
  • -1 unit if it loses.

The +10% is the probability-weighted average produced by the model.

Deriving the formula from possible outcomes

The compact formula is a simplified version of the full expected-profit calculation.

At decimal odds O, a winning one-unit bet produces O - 1 units of net profit. A losing bet produces a net result of -1.

Therefore:

EV = p × (O - 1) + (1 - p) × (-1)
Enter fullscreen mode Exit fullscreen mode

Expanding the expression:

EV = pO - p - 1 + p
EV = pO - 1
Enter fullscreen mode Exit fullscreen mode

That gives us the compact form:

EV = (p × O) - 1
Enter fullscreen mode Exit fullscreen mode

The longer version is useful because it exposes the structure of the calculation. Expected value is not a mysterious score. It is the weighted average of the possible economic results.

Implementing an EV function in Python

The calculation can be expressed in a few lines of code:

def expected_value(
    win_probability: float,
    decimal_odds: float,
    stake: float = 1.0,
) -> float:
    """Return expected net profit for a simple win/lose bet."""

    if not 0 <= win_probability <= 1:
        raise ValueError("win_probability must be between 0 and 1")

    if decimal_odds < 1:
        raise ValueError("decimal_odds must be at least 1.0")

    if stake < 0:
        raise ValueError("stake cannot be negative")

    return stake * (win_probability * decimal_odds - 1)
Enter fullscreen mode Exit fullscreen mode

Example:

ev = expected_value(
    win_probability=0.48,
    decimal_odds=2.20,
    stake=100,
)

print(f"Expected net profit: {ev:.2f} units")
Enter fullscreen mode Exit fullscreen mode

Output:

Expected net profit: 5.60 units
Enter fullscreen mode Exit fullscreen mode

The result means that, under the 48% probability estimate, the position has a theoretical expected value of +5.60 units for every 100 units staked.

It does not mean the individual bet will earn 5.60 units. Its simple realized outcomes are:

Win:  +120 units
Loss: -100 units
Enter fullscreen mode Exit fullscreen mode

Expected value is the model-weighted average of those outcomes.

Break-even probability

A price also tells us the minimum win rate required to break even before fees and execution costs.

For decimal odds:

Break-even probability = 1 / decimal odds
Enter fullscreen mode Exit fullscreen mode

We can implement that directly:

def break_even_probability(decimal_odds: float) -> float:
    if decimal_odds < 1:
        raise ValueError("decimal_odds must be at least 1.0")

    return 1 / decimal_odds
Enter fullscreen mode Exit fullscreen mode

At odds of 2.20:

required_probability = break_even_probability(2.20)

print(f"{required_probability:.2%}")
Enter fullscreen mode Exit fullscreen mode

Output:

45.45%
Enter fullscreen mode Exit fullscreen mode

If your estimated probability is 48%, it is above the 45.45% break-even rate.

That produces:

EV = (0.48 × 2.20) - 1
EV = +5.60%
Enter fullscreen mode Exit fullscreen mode

If your estimate is below 45.45%, the same price becomes negative EV.

Fair odds

A probability estimate can be converted into zero-margin decimal odds:

Fair odds = 1 / estimated probability
Enter fullscreen mode Exit fullscreen mode

For an estimated probability of 48%:

Fair odds = 1 / 0.48
Fair odds = 2.0833
Enter fullscreen mode Exit fullscreen mode

The offered odds are 2.20, which are higher than the estimated fair odds of approximately 2.08.

If fair odds are already available, EV can also be written as:

EV = (offered odds / fair odds) - 1
Enter fullscreen mode Exit fullscreen mode

Using the same example:

EV = (2.20 / 2.0833) - 1
EV ≈ +5.60%
Enter fullscreen mode Exit fullscreen mode

Both approaches are mathematically equivalent.

Price changes the decision

Assume an outcome has an estimated probability of exactly 50%.

Its fair decimal odds are:

1 / 0.50 = 2.00
Enter fullscreen mode Exit fullscreen mode

Now compare three offered prices:

Offered odds Estimated probability EV Interpretation
2.10 50% +5.00% Positive EV under the estimate
2.00 50% 0.00% Theoretical break-even
1.90 50% -5.00% Negative EV under the estimate

Nothing about the event changed. Only the price changed.

This is why odds should be treated as prices rather than as simple labels for favorites and underdogs.

EV is only as reliable as its probability input

The arithmetic is deterministic. The probability estimate is not.

Keeping the offered odds fixed at 2.20 demonstrates how sensitive the result is:

Estimated probability EV at 2.20
50.00% +10.00%
48.00% +5.60%
45.45% approximately 0.00%
44.00% -3.20%

The code returns an exact result for the supplied inputs. That does not make the inputs exact.

Probability estimates can come from:

  • statistical models;
  • simulations;
  • market-derived reference prices;
  • historical data;
  • lineup and availability information;
  • combinations of independent models and market data.

Each source introduces assumptions and uncertainty.

A displayed +1% edge may not be meaningfully different from zero if the probability estimate has a wider error range.

A more honest interpretation is:

Positive EV according to this model, at this price, at this time.

Bookmaker margin complicates implied probability

Raw implied probabilities often include bookmaker margin.

Suppose both outcomes in a two-way market are priced at 1.91.

Each price implies:

1 / 1.91 = 52.36%
Enter fullscreen mode Exit fullscreen mode

Together:

52.36% + 52.36% = 104.72%
Enter fullscreen mode Exit fullscreen mode

Mutually exclusive outcomes cannot have fair probabilities totaling more than 100%.

The excess is the market margin under this simplified interpretation.

If market prices are being used as probability inputs, that margin must be addressed. A basic proportional adjustment is one option, but no de-vig method automatically converts a market price into objective truth.

The adjustment method becomes part of the model.

Positive EV is not win probability

A common mistake is interpreting a +6% EV value as:

  • a 6% probability of winning;
  • a 56% probability of winning;
  • or a guaranteed 6% return.

None of those interpretations is valid.

Consider:

Estimated probability = 22%
Offered odds = 5.00
Enter fullscreen mode Exit fullscreen mode

The expected value is:

EV = (0.22 × 5.00) - 1
EV = +10%
Enter fullscreen mode Exit fullscreen mode

The bet is theoretically +10% EV, yet the model still assigns a 78% probability to it not winning.

A high expected value can coexist with a low win rate.

Why positive-EV decisions still lose

Expected value describes a distribution, not a schedule.

A selection with a 55% estimated probability still has a 45% estimated probability of losing. Several losses can occur consecutively without contradicting that estimate.

This is variance.

Short samples can move far away from the expected average. Therefore:

  • a few wins do not validate a model;
  • a few losses do not invalidate one;
  • realized ROI should not be confused with expected value;
  • bankroll and stake sizing remain separate risk decisions.

Evaluation becomes more useful when it includes both outcome and process data:

  • the probability estimate;
  • the offered price;
  • the break-even probability;
  • the expected value;
  • the stake;
  • the market definition;
  • the price available at execution;
  • a later or closing reference price;
  • the realized result.

EV and ROI are different metrics

Expected value is forward-looking.

It estimates the average result implied by a probability model and the available price before the event is resolved.

ROI is backward-looking:

ROI = realized profit / total amount staked
Enter fullscreen mode Exit fullscreen mode

A strategy can have positive estimated EV and negative realized ROI over a small sample because of variance.

It can also show positive realized ROI despite consistently taking negative-EV prices.

One metric describes the expectation. The other describes what happened.

Both need context.

Expected value and arbitrage are not the same

Expected value and arbitrage both depend on price, but they solve different problems.

A positive-EV position normally:

  • depends on a probability estimate or fair-price reference;
  • remains exposed to the event outcome;
  • can lose even when executed correctly.

An arbitrage position:

  • depends on a combination of prices across all outcomes;
  • attempts to balance returns across those outcomes;
  • can reduce theoretical outcome exposure when every leg is executed correctly.

Arbitrage introduces its own operational risks, including price movement, rejected stakes, limits, partial execution, and mismatched settlement rules.

Neither concept removes the need to verify the market and execution conditions.

Common mistakes

Treating EV as certainty

EV is conditional on a probability estimate. If that estimate is wrong, the true expected value may be lower, zero, or negative.

Confusing EV with win rate

Expected value measures probability-weighted economic value, not how frequently the selection wins.

Ignoring margin

A bookmaker’s raw implied probability may include overround and should not automatically be treated as fair probability.

Comparing different markets

Different handicaps, totals, periods, overtime rules, or participation requirements can create a false apparent edge.

Using a stale price

Expected value depends on the price available when the bet is placed. A calculation based on an expired quote describes a different decision.

Trusting a tiny sample

Short-term results contain substantial variance and provide limited evidence about model quality.

Increasing stakes only because EV looks large

A larger displayed edge is not automatically more reliable. Stake sizing should account for bankroll, estimation error, limits, and execution risk.

A practical workflow

A repeatable process is more useful than an isolated EV percentage:

  1. Record the exact market and offered price.
  2. Establish a defensible probability or fair-price estimate.
  3. Account for market margin when required.
  4. Calculate the break-even probability.
  5. Calculate expected value.
  6. Test how sensitive the result is to estimation error.
  7. Confirm that the compared markets use equivalent rules.
  8. Recheck that the price is still available.
  9. Apply a predefined stake-sizing framework.
  10. Log the inputs, execution, later benchmark, and result.

The goal is not to eliminate uncertainty.

The goal is to make the assumptions visible enough to test, review, and improve.

Final takeaway

Expected value changes the question from:

“Will this bet win?”

to:

“Is the available price favorable relative to a defensible probability estimate?”

The calculation is simple:

EV = (probability × decimal odds) - 1
Enter fullscreen mode Exit fullscreen mode

But the output should never be trusted more than its inputs.

A positive result is not a prediction, guarantee, or substitute for risk management. It is a model-based estimate of decision quality at a specific price.

If you implement EV in code, validate the inputs, preserve the assumptions, and test the sensitivity of the result instead of treating a single number as truth.

Top comments (0)