Skip to main content

Odds Generation — run · inning (baseball)

Enter the full game's Moneyline in decimal and its Total and Run Line quotes in Malay — margins still embedded. Baseball runs are counts but not Poisson: an inning is scoreless ~72% of the time yet carries a fat "big-inning" tail, so a team's game variance (~10) is more than double its mean. The engine (ADR-029):

  1. strips each bookmaker margin (Power method — all three books are two-way);
  2. models each inning as a zero-inflated geometric (mean μ/9, tail q) and back-solves (μ_H, μ_A) by nested bisection — the Total fixes the run environment, the Moneyline fixes the split;
  3. applies the sport's endgame rules — the corrections here are not a statistical tilt but exact stopping rules: the bottom of the 9th is skipped when home already leads, a walk-off stops play the moment the lead is taken (home wins compress toward +1), and extra innings replay until the tie breaks — then re-solves;
  4. optionally fits the big-inning tail q to the Run Line (toggle in the RL box) — the RL is pure dispersion information at a fixed Moneyline, exactly as the ML pins basketball's σ_M;
  5. derives First 5/3/7 innings and Inning 1 markets by convolving the same per-inning distributions — the inning is the period unit, no scaling knobs.
Stage 1 — nine-inning convolution: a zero-inflated geometric inning (~72% scoreless, big-inning tail) convolves nine times into the game distribution
Stage 1 — an inning is scoreless ≈72% of the time with a big-inning tail: zero-inflated geometric innings convolve ⊛9 into the game — σ² > 2μ, counts but not Poisson

Each stage re-solves the same fair targets, so the score grid's stage switcher is a true before/after — flip Convolution / Endgame / RL q and watch the home-win-by-1 stripe fatten.

Moneyline (Decimal) — incl. extras
Total quote (Malay)
Run Line (Malay) ·
Shape priors · margins

/ steps a field, Shift steps bigger; Malay pairs step their partner the opposite way. Quotes are the full game (extra innings included); First-N periods derive by convolving the same per-inning distributions.

Valid inputs: decimals above 1, Malay in [−1, +1] non-zero, each book carrying margin, q in (0.15, 0.8). The solve walks all 18 half-innings — allow it a second.

μ_H 5.6090μ_A 4.3818q 0.6669extras 8.6%round-trip Δp 5.0e-9 / 5.5e-9 / 1.2e-6Convolution → Endgame → RL q
Score grid — P(home = h, away = a) ×100
μ_H 5.609μ_A 4.382q 0.667skip-9 49.6%walk-off 9.2%extras 8.6%
A=0A=1A=2A=3A=4A=5A=6A=7A=8A=9A=10A=11A=12A=13A=14
H=00.01.81.61.41.21.00.80.70.50.40.40.30.20.20.1
H=13.90.01.31.10.90.80.60.50.40.30.30.20.20.10.1
H=22.42.30.01.11.00.80.70.50.40.40.30.20.20.10.1
H=32.11.32.20.01.00.80.70.50.40.30.30.20.20.10.1
H=41.91.11.11.80.00.80.60.50.40.30.30.20.20.10.1
H=51.61.00.90.91.50.00.60.50.40.30.20.20.10.10.1
H=61.40.80.80.70.71.20.00.40.40.30.20.20.10.10.1
H=71.20.70.60.60.50.50.90.00.30.30.20.20.10.10.1
H=81.00.60.50.50.40.40.40.60.00.20.20.10.10.10.1
H=90.80.50.40.40.30.30.30.20.40.00.20.10.10.10.0
H=100.70.40.40.30.30.20.20.20.20.30.00.10.10.10.0
H=110.50.30.30.30.20.20.20.10.10.10.20.00.10.00.0
H=120.40.30.20.20.20.20.10.10.10.10.10.10.00.00.0
H=130.30.20.20.20.10.10.10.10.10.10.00.00.10.00.0
H=140.30.10.10.10.10.10.10.10.10.00.00.00.00.10.0
home win tie away winsettlement grid — extras resolved; note the fat home-win-by-1 stripe (walk-offs)
5 in scope
settles after extra innings — the endgame construction leaves no tie mass
OutcomeFairDecPricedMalay
Home58.7%1.7031.667+0.67
Away41.3%2.4232.339-0.75
How these numbers are computed
1 · Strip the bookmaker margins (Power method — all books two-way)
Moneyline (extra innings included) → P(home wins)
HomeAway
Decimal quote1.652.30
Decimal dd1.65002.3000
Implied q=1/dq = 1/d0.60610.4348
Fair p=q1/xp = q^{1/x}0.58730.4127
Fair decimal 1/p1/p1.70262.4233
overround Q = 1.0408 → solve q11/x+q21/x=1q_1^{1/x} + q_2^{1/x} = 1 → x = 0.9410fair P(home ML) = 58.73%
Total 8.50 → P(over)
OverUnder
Malay quote+0.90+0.92
Decimal dd1.90001.9200
Implied q=1/dq = 1/d0.52630.5208
Fair p=q1/xp = q^{1/x}0.50280.4972
Fair decimal 1/p1/p1.98882.0113
overround Q = 1.0471 → solve q11/x+q21/x=1q_1^{1/x} + q_2^{1/x} = 1 → x = 0.9335fair P(over) = 50.28%
Run Line -1.50 → P(home covers)
HomeAway
Malay quote-0.80+0.72
Decimal dd2.25001.7200
Implied q=1/dq = 1/d0.44440.5814
Fair p=q1/xp = q^{1/x}0.43070.5693
Fair decimal 1/p1/p2.32181.7565
overround Q = 1.0258 → solve q11/x+q21/x=1q_1^{1/x} + q_2^{1/x} = 1 → x = 0.9627fair P(home covers) = 43.07%

Standalone strips: Margin — two-way (Power).

2 · The inning model — zero-inflated geometric runs

Runs are not Poisson: an inning is scoreless ≈ 72% of the time yet carries a fat “big inning” tail, so a team's game variance (≈ 10) is more than double its mean (≈ 4.6). Each inning draws

P(0)=π=1m(1q)P(k1)=(1π)(1q)qk1m=μ/9P(0) = \pi = 1 - m(1-q) \qquad P(k \ge 1) = (1-\pi)(1-q)\,q^{\,k-1} \qquad m = \mu/9

— the mean per inning mm carries the team rate and the tail qq is the big-inning knob (this run: home π=0.792\pi = 0.792, q = 0.667). A team's nine innings convolve into its runs distribution, and the two teams multiply into the score grid. The Total is the size and the Moneyline is the split — the same nested bisection as goal-regular recovers (μH,μA)=(5.609, 4.382)(\mu_H, \mu_A) = (5.609,\ 4.382) so both fair targets hold on the settlement grid.

3 · Endgame rules — the corrections are the sport's own stopping rules

Basketball needed a tie-inflation ι; baseball's corrections are deterministic rules, applied on the inning walk: the bottom of the 9th is skipped when home already leads (49.6% here — the home total is truncated); a walk-off stops play the moment home takes the lead, compressing home wins toward +1 (margin mix {1: 75%, 2: 14%, 3: 6%, 4: 5%}); extra innings (8.6%) replay until the tie breaks, at 2.00× the inning rate (the ghost-runner era). Every stage re-solves the same fair targets:

Stageμ_Hμ_Aqskip-9walk-offextrasΔ MLΔ totalΔ RL
Convolution4.9524.1080.4600.0%0.0%0.0%8.9e-91.1e-81.2e-3
Endgame4.9484.0910.46048.0%10.8%9.7%6.1e-91.9e-94.2e-2
RL q5.6094.3820.66749.6%9.2%8.6%5.0e-95.5e-91.2e-6

The RL stage bisects q until the grid reproduces the stripped Run Line — the RL is pure dispersion information at a fixed ML, exactly as the ML pins basketball’s σ_M. Note μ's are hypothetical full-nine rates: the settled total mean sits below them because skipped bottom-9s and walk-offs remove runs.

4 · Periods — first-N-innings convolutions

Baseball's period model needs no scaling knobs: the inning is the unit. First-5 markets convolve the same per-inning distributions five times; ties are real outcomes there, so the F5 moneyline pushes on a tie (R = 18.2% here, fair home = W/(1R)W/(1-R) = 57.68%). The endgame rules never touch innings 1–8, so first-N grids are rule-free by construction. Inning weights (starters vs bullpen, top of the order in inning 1) are a calibration refinement — ADR-029 O1.

5 · Read “Moneyline” off the grid · margins · notes

Home sums cells with h > a. Full game: the endgame construction leaves no tie mass. First-N periods: a tie pushes, fair = W/(1−R). Fair groups are re-margined exactly as in goal-regular (Power ladder two-way, Shin multi-way).

targets  tW = powerStrip(ML pair)      tO = powerStrip(Total pair)      tR = powerStrip(RL pair)

stage ∈ {Convolution, Endgame, RL q}:          # each re-solves the same targets
  bisect μ_total (size)  until P(over T | grid)  = tO     # outer — goal-regular's solveLambdas
    bisect μ_H   (split) until P(home ML | grid) = tW     # inner
  RL stage: bisect q until P(home covers | grid) = tR

grid: per-inning ZIG(m = μ/9, q) → innings 1–8 convolve → top 9 → bottom 9
      skipped if home leads · walk-off stops play (margin mix 1–4) · extras ×2.00
periods: first-N convolutions of the same inning pmfs (no endgame rules)

Grid runs 0..34 runs a side (tail mass clamps into the last cell). Engine + invariants: docs/src/lib/odds/baseball.ts, __tests__/baseball.test.ts; decision record ADR-029.