Skip to content

betting_combat.rounds.features.rates

Group 1b: every fighter’s history rates exponentially weighted in time, as of each fight.

A fight t years before counts 0.5 ** (t / half_life); the league rate each fighter is pulled toward is weighted the same way (FighterHistory pulls toward the all-time rate). The rates, their denominators and the shrinkage are FighterHistory’s results and survival blocks, from strictly earlier dates only; with half_life=None (every fight counting the same) they ARE FighterHistory’s (tests/parity/test_layer1_v2.py).

dec_rate decisions per fight (3 pseudo-fights toward the league) finish_win_rate, ko_win_rate, sub_win_rate got_ko_rate, got_sub_rate, got_rate per decided fight (wins + losses; 3 pseudo-fights) past_r1 went past round 1, per fight scheduled long enough (2 pseudo-fights) avg_fight_min minutes per fight (no shrinkage; NaN before the first fight) eff_n the weighted number of earlier fights

Per fight (fight_rates): s_<rate> (A + B) and d_<rate> (A - B), A the dataset’s slot (dataset.a_slot_of), and eff_n_min (the fewer of the two). The clock’s going-the-distance and KO-share models read them (clock_v2; half-lives 1 and 8 years). Research: data/ufc/cito/assess/job/j02_rates.py (2026-10-25).

Classes

RecencyRates

The rates with half_life (years; None = equal weights = FighterHistory).

fight_rates

fight_rates(a_slot: pd.Series, prefix: str = '') -> pd.DataFrame

One row per fight (index fight_id): <prefix>s_<rate> (A + B), <prefix>d_<rate> (A - B) and <prefix>eff_n_min; a_slot: fight_id -> A’s slot (1 or 2).

fighter_rates

fighter_rates() -> pd.DataFrame

One row per (fight_id, fighter_id): the rates as of that fight.