From 6af121be9aef9b4c51bfd7866ddfb9b38e6b5576 Mon Sep 17 00:00:00 2001 From: georgedouzas Date: Tue, 3 Oct 2023 14:22:24 +0300 Subject: [PATCH] chore: Predictions 03/10/2023 --- README.md | 97 ++++++++++++++----------------------------------------- 1 file changed, 25 insertions(+), 72 deletions(-) diff --git a/README.md b/README.md index cc1df28..940b6ca 100644 --- a/README.md +++ b/README.md @@ -47,80 +47,34 @@ use the predictions for your own betting. **Value bets** -| Date | League | Home Team | Away Team | Home Win | Draw | Away Win | Over 2.5 | Under 2.5 | -|:-----------|:------------|:--------------|:-----------------|-----------:|-------:|-----------:|-----------:|------------:| -| 2023-10-01 | Italy | Bologna | Empoli | 2.27 | 4.12 | 3.92 | 1.8 | 2.24 | -| 2023-10-01 | Italy | Udinese | Genoa | 2.49 | 4.17 | 3.6 | 1.92 | 2.09 | -| 2023-10-01 | Turkey | Konyaspor | Besiktas | 2.57 | 4.05 | 3.38 | 1.85 | 2.17 | -| 2023-10-01 | France | Toulouse | Metz | 2.7 | 4.32 | 3.35 | 1.84 | 2.19 | -| 2023-10-01 | France | Lorient | Montpellier | 2.57 | 4.11 | 3.38 | 1.86 | 2.16 | -| 2023-10-01 | France | Rennes | Nantes | 2.05 | 4.41 | 4.81 | 1.87 | 2.15 | -| 2023-10-01 | England | Blackburn | Leicester | 2.57 | 4.22 | 3.38 | 1.85 | 2.18 | -| 2023-10-01 | Germany | Darmstadt | Werder Bremen | 2.57 | 4.02 | 3.28 | 1.71 | 2.42 | -| 2023-10-01 | Germany | Freiburg | Augsburg | 2.06 | 4.05 | 4.5 | 1.67 | 2.5 | -| 2023-10-01 | France | Nice | Brest | 2.29 | 4.14 | 3.78 | 1.8 | 2.25 | -| 2023-10-01 | France | Reims | Lyon | 2.45 | 4.21 | 3.45 | 1.95 | 2.05 | -| 2023-10-01 | Greece | Volos NFC | Panserraikos | 2.49 | 3.01 | 3.51 | 1.95 | 2.05 | -| 2023-10-01 | Germany | Elversberg | Greuther Furth | 2.5 | 3.82 | 3.4 | 1.67 | 2.48 | -| 2023-10-01 | Greece | Lamia | Panetolikos | 2.34 | 4.53 | 3.83 | 1.94 | 2.06 | -| 2023-10-01 | England | Nott'm Forest | Brentford | 2.57 | 4.33 | 3.4 | 1.95 | 2.05 | -| 2023-10-01 | Belgium | RWD Molenbeek | Gent | 2.83 | 4.3 | 2.44 | 1.8 | 2.25 | -| 2023-10-01 | Belgium | Club Brugge | St Truiden | 1.6 | 4.41 | 5.03 | 1.86 | 2.16 | -| 2023-10-01 | Greece | Aris | Kifisias | 1.71 | 4.6 | 5.48 | 2.02 | 1.98 | -| 2023-10-01 | Greece | Panathinaikos | PAOK | 2.34 | 4.31 | 3.83 | 1.95 | 2.06 | -| 2023-10-01 | Greece | Giannina | Olympiakos | 3.19 | 4.55 | 1.71 | 2.02 | 1.98 | -| 2023-10-01 | Germany | Osnabruck | Kaiserslautern | 2.57 | 4.8 | 2.44 | 1.73 | 2.37 | -| 2023-10-01 | France | Le Havre | Lille | 2.79 | 4.37 | 2.6 | 1.86 | 2.16 | -| 2023-10-01 | Portugal | Arouca | Chaves | 2.34 | 4.58 | 3.67 | 1.81 | 2.23 | -| 2023-10-01 | Germany | Nurnberg | Magdeburg | 2.57 | 4.05 | 3.28 | 1.67 | 2.48 | -| 2023-10-01 | Spain | Zaragoza | Mirandes | 2.25 | 4.11 | 3.98 | 1.94 | 2.06 | -| 2023-10-01 | Italy | Cremonese | Parma | 2.49 | 4.17 | 3.57 | 1.73 | 2.38 | -| 2023-10-01 | Spain | Amorebieta | Cartagena | 2.2 | 4.31 | 3.54 | 1.95 | 2.05 | -| 2023-10-01 | Turkey | Fenerbahce | Rizespor | 1.55 | 4.78 | 5.37 | 1.75 | 2.33 | -| 2023-10-01 | Turkey | Karagumruk | Kasimpasa | 2.51 | 4.11 | 3.51 | 1.82 | 2.22 | -| 2023-10-01 | Turkey | Ad. Demirspor | Alanyaspor | 2.34 | 4.22 | 3.75 | 1.77 | 2.3 | -| 2023-10-01 | Spain | Huesca | Sp Gijon | 2.51 | 4.28 | 3.92 | 1.96 | 2.04 | -| 2023-10-01 | Belgium | Genk | Westerlo | 1.91 | 4.41 | 4.8 | 1.86 | 2.16 | -| 2023-10-01 | Italy | Atalanta | Juventus | 2.64 | 3.98 | 3.51 | 1.84 | 2.18 | -| 2023-10-01 | Italy | Roma | Frosinone | 1.56 | 4.31 | 5.48 | 1.87 | 2.15 | -| 2023-10-01 | Italy | Bari | Como | 2.48 | 3.34 | 3.6 | 1.93 | 2.08 | -| 2023-10-01 | Italy | Cittadella | Lecco | 2.27 | 4.06 | 3.92 | 1.87 | 2.14 | -| 2023-10-01 | Spain | Valladolid | Burgos | 2.25 | 4.11 | 4.05 | 1.94 | 2.06 | -| 2023-10-01 | Italy | Sampdoria | Catanzaro | 2.48 | 3.98 | 3.53 | 1.9 | 2.11 | -| 2023-10-01 | Italy | Palermo | Sudtirol | 1.86 | 4 | 3.4 | 1.91 | 2.1 | -| 2023-10-01 | Netherlands | Excelsior | Sparta Rotterdam | 2.57 | 4.21 | 3.38 | 1.81 | 2.23 | -| 2023-10-01 | Netherlands | Heracles | Zwolle | 2.26 | 4.18 | 3.53 | 1.78 | 2.29 | -| 2023-10-01 | Belgium | St. Gilloise | Charleroi | 2.21 | 4.41 | 3.92 | 1.8 | 2.25 | -| 2023-10-01 | Netherlands | AZ Alkmaar | For Sittard | 1.55 | 4.78 | 5.97 | 1.84 | 2.19 | -| 2023-10-01 | Portugal | Guimaraes | Estoril | 2.34 | 4.28 | 3.83 | 1.84 | 2.2 | -| 2023-10-01 | Portugal | Rio Ave | Moreirense | 2.47 | 4.2 | 3.51 | 1.86 | 2.16 | -| 2023-10-01 | Spain | Almeria | Granada | 2.4 | 4.18 | 3.65 | 1.83 | 2.21 | -| 2023-10-01 | Spain | Alaves | Osasuna | 2.62 | 4.28 | 3.55 | 2 | 2 | -| 2023-10-01 | Spain | Ath Madrid | Cadiz | 1.5 | 4.78 | 5.53 | 1.98 | 2.02 | -| 2023-10-01 | Spain | Betis | Valencia | 2.47 | 4.46 | 3.54 | 1.87 | 2.14 | -| 2023-10-01 | Spain | Eldense | Oviedo | 2.69 | 4.28 | 3.55 | 1.99 | 2.01 | -| 2023-10-01 | Netherlands | Nijmegen | Vitesse | 2.47 | 4.11 | 3.53 | 1.82 | 2.22 | -| 2023-10-02 | Italy | Fiorentina | Cagliari | 1.84 | 3.87 | 5.48 | 1.87 | 2.15 | -| 2023-10-02 | Italy | Sassuolo | Monza | 2.49 | 4.04 | 3.4 | 1.8 | 2.24 | -| 2023-10-02 | Italy | Torino | Verona | 2.29 | 4.15 | 3.83 | 1.84 | 2.19 | -| 2023-10-02 | Spain | Espanol | Ferrol | 2.25 | 4.2 | 3.95 | 1.92 | 2.09 | -| 2023-10-02 | Portugal | Gil Vicente | Casa Pia | 2.47 | 4.18 | 3.51 | 1.86 | 2.16 | -| 2023-10-02 | France | Ajaccio | Bastia | 2.53 | 4.28 | 3.66 | 1.92 | 2.08 | -| 2023-10-02 | Greece | OFI Crete | AEK | 2.87 | 4.45 | 1.71 | 1.95 | 2.05 | -| 2023-10-02 | Spain | Las Palmas | Celta | 2.54 | 4.28 | 3.62 | 1.89 | 2.12 | -| 2023-10-02 | England | Fulham | Chelsea | 2.6 | 4.39 | 3.34 | 1.92 | 2.09 | -| 2023-10-02 | Greece | Atromitos | Asteras Tripolis | 2.48 | 4.28 | 3.65 | 2.12 | 1.9 | -| 2023-10-02 | Turkey | Kayserispor | Buyuksehyr | 2.57 | 4.29 | 3.51 | 1.83 | 2.21 | +| Date | League | Home Team | Away Team | Home Win | Draw | Away Win | Over 2.5 | Under 2.5 | +|:-----------|:---------|:-------------|:-------------|-----------:|-------:|-----------:|-----------:|------------:| +| 2023-10-04 | England | Coventry | Blackburn | 2.31 | 4.18 | 3.66 | 1.81 | 2.23 | +| 2023-10-04 | England | Boreham Wood | Hartlepool | 2.11 | 3.98 | 3.64 | 2.07 | 1.93 | +| 2023-10-04 | France | St Etienne | Dunkerque | 1.81 | 5.34 | 4.11 | 1.81 | 2.23 | +| 2023-10-04 | England | Swansea | Norwich | 2.54 | 4.32 | 3.48 | 1.9 | 2.11 | +| 2023-10-04 | England | Sunderland | Watford | 2.28 | 4.12 | 3.73 | 1.89 | 2.12 | +| 2023-10-04 | England | Leicester | Preston | 1.5 | 4.41 | 4.68 | 1.9 | 2.11 | +| 2023-10-04 | Spain | Oviedo | Huesca | 2.12 | 4.28 | 4.19 | 1.99 | 2.01 | +| 2023-10-04 | England | Rotherham | Bristol City | 2.6 | 4.18 | 3.44 | 1.91 | 2.1 | +| 2023-10-04 | Spain | Eldense | Valladolid | 2.58 | 4.39 | 3.62 | 1.57 | 2.75 | +| 2023-10-04 | Spain | Burgos | Leganes | 2.34 | 4.28 | 3.97 | 1.94 | 2.06 | +| 2023-10-04 | Spain | Sp Gijon | Elche | 2.36 | 4.38 | 3.79 | 1.92 | 2.09 | +| 2023-10-04 | England | Leeds | QPR | 1.5 | 4.91 | 4.83 | 1.9 | 2.11 | +| 2023-10-05 | Spain | Mirandes | Eibar | 2.62 | 4.21 | 3.64 | 1.98 | 2.02 | +| 2023-10-05 | Spain | Ferrol | Amorebieta | 2.11 | 4.06 | 4.19 | 1.97 | 2.03 | +| 2023-10-05 | Spain | Andorra | Zaragoza | 2.32 | 4.38 | 3.82 | 1.96 | 2.04 | +| 2023-10-05 | Spain | Cartagena | Espanol | 2.6 | 4.49 | 2.72 | 1.7 | 2.43 | **Backtesting results** | Training Start | Training End | Training Period | Testing Start | Testing End | Testing Period | Start Value | End Value | Total Return [%] | Total Bets | Win Rate [%] | Best Bet [%] | Worst Bet [%] | Avg Winning Bet [%] | Avg Losing Bet [%] | Profit Factor | Sharpe Ratio | Avg Bet Yield [%] | Std Bet Yield [%] | |:--------------------|:--------------------|:-------------------|:--------------------|:--------------------|:------------------|--------------:|------------:|-------------------:|-------------:|---------------:|---------------:|----------------:|----------------------:|---------------------:|----------------:|---------------:|--------------------:|--------------------:| -| 2016-01-08 00:00:00 | 2017-09-23 00:00:00 | 624 days 00:00:00 | 2017-09-23 00:00:00 | 2018-11-23 00:00:00 | 427 days 00:00:00 | 1000 | 1000 | 0 | 0 | nan | nan | nan | nan | nan | nan | inf | nan | nan | -| 2016-01-08 00:00:00 | 2018-11-23 00:00:00 | 1050 days 00:00:00 | 2018-11-23 00:00:00 | 2020-01-11 00:00:00 | 415 days 00:00:00 | 1000 | 1156.87 | 15.687 | 622 | 49.5177 | 674 | -175 | 77.1742 | -64.2006 | 1.15485 | 1.26801 | 6.11455 | 96.0011 | -| 2016-01-08 00:00:00 | 2020-01-11 00:00:00 | 1464 days 00:00:00 | 2020-01-11 00:00:00 | 2021-04-16 00:00:00 | 462 days 00:00:00 | 1000 | 1529.91 | 52.991 | 1665 | 48.2883 | 1033.33 | -183.333 | 84.9691 | -69.6008 | 1.20502 | 2.63005 | 5.16376 | 106.067 | -| 2016-01-08 00:00:00 | 2021-04-16 00:00:00 | 1925 days 00:00:00 | 2021-04-16 00:00:00 | 2022-07-31 00:00:00 | 472 days 00:00:00 | 1000 | 1766.97 | 76.697 | 1485 | 50.5724 | 573.25 | -183.333 | 80.2816 | -64.9321 | 1.33934 | 3.50553 | 8.59336 | 97.5795 | -| 2016-01-08 00:00:00 | 2022-07-31 00:00:00 | 2396 days 00:00:00 | 2022-07-31 00:00:00 | 2023-09-28 00:00:00 | 425 days 00:00:00 | 1000 | 1225.3 | 22.53 | 1430 | 47.2028 | 436.4 | -180 | 75.0159 | -68.3229 | 1.09758 | 1.19924 | -0.471869 | 93.7992 | +| 2016-01-08 00:00:00 | 2017-09-24 00:00:00 | 625 days 00:00:00 | 2017-09-24 00:00:00 | 2018-11-24 00:00:00 | 427 days 00:00:00 | 1000 | 1000 | 0 | 0 | nan | nan | nan | nan | nan | nan | inf | nan | nan | +| 2016-01-08 00:00:00 | 2018-11-24 00:00:00 | 1051 days 00:00:00 | 2018-11-24 00:00:00 | 2020-01-18 00:00:00 | 421 days 00:00:00 | 1000 | 1210.09 | 21.009 | 654 | 48.7768 | 798.857 | -171.429 | 80.5486 | -62.992 | 1.20023 | 1.6278 | 7.21506 | 97.3386 | +| 2016-01-08 00:00:00 | 2020-01-18 00:00:00 | 1471 days 00:00:00 | 2020-01-18 00:00:00 | 2021-04-18 00:00:00 | 457 days 00:00:00 | 1000 | 1679.13 | 67.913 | 1650 | 48.4848 | 857.143 | -183.333 | 86.4132 | -65.8668 | 1.27038 | 3.061 | 8.08571 | 104.662 | +| 2016-01-08 00:00:00 | 2021-04-18 00:00:00 | 1927 days 00:00:00 | 2021-04-18 00:00:00 | 2022-08-12 00:00:00 | 482 days 00:00:00 | 1000 | 1698.32 | 69.832 | 1507 | 49.2369 | 573.25 | -184.615 | 82.9942 | -65.4116 | 1.30385 | 3.27374 | 7.70223 | 100.283 | +| 2016-01-08 00:00:00 | 2022-08-12 00:00:00 | 2408 days 00:00:00 | 2022-08-12 00:00:00 | 2023-10-02 00:00:00 | 417 days 00:00:00 | 1000 | 1322.82 | 32.282 | 1423 | 47.8566 | 410 | -181.818 | 74.9283 | -67.8241 | 1.14172 | 1.69528 | 0.587734 | 93.3722 | ## Quick start @@ -134,8 +88,7 @@ and dropping columns that contain more than 20% of missing values: ```python leagues = ['England', 'Scotland', 'Germany', 'Italy', 'Spain', 'France', 'Netherlands', 'Belgium', 'Portugal', 'Turkey', 'Greece'] -years = [2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024] -data_sources = ['footballdata'] +years = [2017, 2018, 2019, 2020, 2021, 2022, 2023] odds_type = 'market_maximum' drop_na_thres = 0.8 ``` @@ -176,7 +129,7 @@ Using the above selections, the betting process is the following: ```python from sportsbet.datasets import SoccerDataLoader -dataloader = SoccerDataLoader({'league': leagues, 'year': years, 'data_source': data_sources}) +dataloader = SoccerDataLoader({'league': leagues, 'year': years}) X_train, Y_train, O_train = dataloader.extract_train_data(drop_na_thres=drop_na_thres, odds_type=odds_type) X_fix, _, O_fix = dataloader.extract_fixtures_data() ```