Wide per-event mart. Joins event metadata from sources.ended_events (with the human-readable time_status from seeds__time_status) and every matches_1 … matches_18 calculation through left joins on (event_id, event_date, event_partition_key).
flowchart LR
ee[/sources.ended_events/] --> me[/mart.matches/]
ts[(seeds__time_status)] --> me
m1[/matches_1_odds_prematch/] --> me
m2[/matches_2_odds_inplay_home/] --> me
m3[/matches_3_odds_inplay_draw/] --> me
m4[/matches_4_odds_inplay_away/] --> me
m5[/matches_5_score/] --> me
m6[/matches_6_team_stats_window/] --> me
m7[/matches_7_league_stats_window/] --> me
m8[/matches_8_team_strength/] --> me
m9[/matches_9_expected_goals/] --> me
m10[/matches_10_overperformance/] --> me
m11[/matches_11_probability/] --> me
m12[/matches_12_prob_win/] --> me
m13[/matches_13_prob_goal_diff/] --> me
m14[/matches_14_prob_goals_total/] --> me
m15[/matches_15_strat_expected_value/] --> me
m16[/matches_16_strat_kelly_criterion/] --> me
m17[/matches_17_strat_predicted/] --> me
m18[/matches_18_strat_bet/] --> me
me -.-> none((terminal — consumed by dashboards / backtests))
click ee "/sources/ended_events/" "Open"
click m1 "/calculations/matches_1_odds_prematch/" "Open"
click m2 "/calculations/matches_2_odds_inplay_home/" "Open"
click m3 "/calculations/matches_3_odds_inplay_draw/" "Open"
click m4 "/calculations/matches_4_odds_inplay_away/" "Open"
click m5 "/calculations/matches_5_score/" "Open"
click m6 "/calculations/matches_6_team_stats_window/" "Open"
click m7 "/calculations/matches_7_league_stats_window/" "Open"
click m8 "/calculations/matches_8_team_strength/" "Open"
click m9 "/calculations/matches_9_expected_goals/" "Open"
click m10 "/calculations/matches_10_overperformance/" "Open"
click m11 "/calculations/matches_11_probability/" "Open"
click m12 "/calculations/matches_12_prob_win/" "Open"
click m13 "/calculations/matches_13_prob_goal_diff/" "Open"
click m14 "/calculations/matches_14_prob_goals_total/" "Open"
click m15 "/calculations/matches_15_strat_expected_value/" "Open"
click m16 "/calculations/matches_16_strat_kelly_criterion/" "Open"
click m17 "/calculations/matches_17_strat_predicted/" "Open"
click m18 "/calculations/matches_18_strat_bet/" "Open"
| Column | Description | Formula |
|---|
event_id | Bet365 event identifier. | ee.event_id |
event_date | Event date. | ee.event_date |
event_partition_key | ClickHouse partition key. | ee.event_partition_key |
event_time_status | Human-readable time status (Not Started / InPlay / Ended / …). | ts.time_status (joined on time_status_id) |
league_id | League id. | ee.league_id |
league_name | League name. | ee.league_name |
league_country_code | League ISO country. | ee.league_country_code |
team_home_id | Home team id. | ee.team_home_id |
team_home_name | Home team name. | ee.team_home_name |
team_home_country_code | Home ISO country. | ee.team_home_country_code |
team_home_image_id | Home logo id. | ee.team_home_image_id |
team_away_id | Away team id. | ee.team_away_id |
team_away_name | Away team name. | ee.team_away_name |
team_away_country_code | Away ISO country. | ee.team_away_country_code |
team_away_image_id | Away logo id. | ee.team_away_image_id |
short_score | Final score string. | ee.short_score |
| Column | Formula |
|---|
odds_prematch_first_home | m1.odds_prematch_first_home |
odds_prematch_last_home | m1.odds_prematch_last_home |
odds_prematch_first_draw | m1.odds_prematch_first_draw |
odds_prematch_last_draw | m1.odds_prematch_last_draw |
odds_prematch_first_away | m1.odds_prematch_first_away |
odds_prematch_last_away | m1.odds_prematch_last_away |
| Column | Formula |
|---|
odds_inplay_count_home | m2.odds_inplay_count_home |
odds_inplay_first_home | m2.odds_inplay_first_home |
odds_inplay_last_home | m2.odds_inplay_last_home |
odds_inplay_avg_home | m2.odds_inplay_avg_home |
odds_inplay_std_home | m2.odds_inplay_std_home |
odds_extreme_max_home_minute_id | m2.max_home_odd_minute_id |
odds_extreme_max_home_score | m2.max_home_odd_short_score |
odds_extreme_max_home | m2.max_home_odd |
odds_extreme_min_home_minute_id | m2.min_home_odd_minute_id |
odds_extreme_min_home_score | m2.min_home_odd_short_score |
odds_extreme_min_home | m2.min_home_odd |
| Column | Formula |
|---|
odds_inplay_first_draw | m3.odds_inplay_first_draw |
odds_inplay_last_draw | m3.odds_inplay_last_draw |
odds_inplay_avg_draw | m3.odds_inplay_avg_draw |
odds_inplay_std_draw | m3.odds_inplay_std_draw |
odds_extreme_max_draw_minute_id | m3.max_draw_odd_minute_id |
odds_extreme_max_draw_score | m3.max_draw_odd_short_score |
odds_extreme_max_draw | m3.max_draw_odd |
odds_extreme_min_draw_minute_id | m3.min_draw_odd_minute_id |
odds_extreme_min_draw_score | m3.min_draw_odd_short_score |
odds_extreme_min_draw | m3.min_draw_odd |
| Column | Formula |
|---|
odds_inplay_first_away | m4.odds_inplay_first_away |
odds_inplay_last_away | m4.odds_inplay_last_away |
odds_inplay_avg_away | m4.odds_inplay_avg_away |
odds_inplay_std_away | m4.odds_inplay_std_away |
odds_extreme_max_away_minute_id | m4.max_away_odd_minute_id |
odds_extreme_max_away_score | m4.max_away_odd_short_score |
odds_extreme_max_away | m4.max_away_odd |
odds_extreme_min_away_minute_id | m4.min_away_odd_minute_id |
odds_extreme_min_away_score | m4.min_away_odd_short_score |
odds_extreme_min_away | m4.min_away_odd |
| Column | Formula |
|---|
score_home | m5.score_home |
score_away | m5.score_away |
score_total | m5.score_total |
score_difference | m5.score_difference |
score_winner | m5.score_winner |
| Column | Formula |
|---|
stats_goals_scored_avg_home | m6.stats_goals_scored_avg_home |
stats_goals_scored_count_home | m6.stats_goals_scored_count_home |
stats_goals_conceded_avg_home | m6.stats_goals_conceded_avg_home |
stats_goals_conceded_count_home | m6.stats_goals_conceded_count_home |
stats_goals_scored_avg_away | m6.stats_goals_scored_avg_away |
stats_goals_scored_count_away | m6.stats_goals_scored_count_away |
stats_goals_conceded_avg_away | m6.stats_goals_conceded_avg_away |
stats_goals_conceded_count_away | m6.stats_goals_conceded_count_away |
| Column | Formula |
|---|
stats_goals_league_avg_home | m7.stats_goals_league_avg_home |
stats_goals_league_avg_away | m7.stats_goals_league_avg_away |
| Column | Formula |
|---|
stats_attack_home | m8.stats_attack_home |
stats_attack_away | m8.stats_attack_away |
stats_defense_home | m8.stats_defense_home |
stats_defense_away | m8.stats_defense_away |
| Column | Formula |
|---|
stats_goals_expected_home | m9.stats_goals_expected_home |
stats_goals_expected_away | m9.stats_goals_expected_away |
stats_goals_expected_total | m9.stats_goals_expected_total |
| Column | Formula |
|---|
overperformance_home_scored | m10.overperformance_home_scored |
overperformance_home_conceded | m10.overperformance_home_conceded |
overperformance_away_scored | m10.overperformance_away_scored |
overperformance_away_conceded | m10.overperformance_away_conceded |
overperformance_goals_total | m10.overperformance_goals_total |
overperformance_goal_difference_home | m10.overperformance_goal_difference_home |
overperformance_goal_difference_away | m10.overperformance_goal_difference_away |
| Column | Formula |
|---|
prob_implied_home | m11.prob_implied_home |
prob_implied_draw | m11.prob_implied_draw |
prob_implied_away | m11.prob_implied_away |
odds_margin | m11.odds_margin |
| Column | Formula |
|---|
prob_home_win | m12.prob_home_win |
prob_draw | m12.prob_draw |
prob_away_win | m12.prob_away_win |
prob_win_sum | m12.prob_win_sum |
| Column | Formula |
|---|
prob_goal_diff_neg3_minus | m13.prob_goal_diff_neg3_minus |
prob_goal_diff_neg3 | m13.prob_goal_diff_neg3 |
prob_goal_diff_neg2 | m13.prob_goal_diff_neg2 |
prob_goal_diff_neg1 | m13.prob_goal_diff_neg1 |
prob_goal_diff_0 | m13.prob_goal_diff_0 |
prob_goal_diff_1 | m13.prob_goal_diff_1 |
prob_goal_diff_2 | m13.prob_goal_diff_2 |
prob_goal_diff_3 | m13.prob_goal_diff_3 |
prob_goal_diff_3_plus | m13.prob_goal_diff_3_plus |
| Column | Formula |
|---|
prob_goals_total_0 | m14.prob_goals_total_0 |
prob_goals_total_1 | m14.prob_goals_total_1 |
prob_goals_total_2 | m14.prob_goals_total_2 |
prob_goals_total_3 | m14.prob_goals_total_3 |
prob_goals_total_4 | m14.prob_goals_total_4 |
prob_goals_total_5 | m14.prob_goals_total_5 |
prob_goals_total_6 | m14.prob_goals_total_6 |
prob_goals_total_7 | m14.prob_goals_total_7 |
prob_goals_total_7_plus | m14.prob_goals_total_7_plus |
| Column | Formula |
|---|
strat_expected_value_home | m15.strat_expected_value_home |
strat_expected_value_draw | m15.strat_expected_value_draw |
strat_expected_value_away | m15.strat_expected_value_away |
| Column | Formula |
|---|
strat_kelly_criterion_home | m16.strat_kelly_criterion_home |
strat_kelly_criterion_draw | m16.strat_kelly_criterion_draw |
strat_kelly_criterion_away | m16.strat_kelly_criterion_away |
| Column | Formula |
|---|
strat_predicted_winner | m17.strat_predicted_winner |
strat_actual_winner | m17.strat_actual_winner |
strat_predicted_winner_odd | m17.strat_predicted_winner_odd |
strat_predicted_winner_kelly | m17.strat_predicted_winner_kelly |
strat_predicted_winner_ev | m17.strat_predicted_winner_ev |
strat_predicted_winner_implied_prob | m17.strat_predicted_winner_implied_prob |
strat_predicted_winner_prob | m17.strat_predicted_winner_prob |
| Column | Formula |
|---|
strat_bet_percentage | m18.strat_bet_percentage |
strat_bet_win_flag | m18.strat_bet_win_flag |
strat_bet_gross_profit | m18.strat_bet_gross_profit |
strat_bet_net_profit | m18.strat_bet_net_profit |
strat_bet_edge | m18.strat_bet_edge |