Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel
Integration:  git
f0b87d3693
feat: football score web scraper
1 month ago
6cba7d1d86
feat: compute and display team stats in html
1 month ago
f0b87d3693
feat: football score web scraper
1 month ago
0ff78361c4
chore: update readme
1 month ago
6cba7d1d86
feat: compute and display team stats in html
1 month ago
6cba7d1d86
feat: compute and display team stats in html
1 month ago
6cba7d1d86
feat: compute and display team stats in html
1 month ago
6cba7d1d86
feat: compute and display team stats in html
1 month ago
6cba7d1d86
feat: compute and display team stats in html
1 month ago
Storage Buckets

README.md

You have to be logged in to leave a comment. Sign In

football-score-selenium-webscraper

Context

This project aims to simplify the process of tracking football scores for in-depth analysis by developing a web scraping program. --> source

Objective

Leveraging Selenium WebDriver, the program automates the extraction of pertinent football match data from a designated website. The extracted data is then seamlessly loaded into a CSV file, streamlining the analytical workflow. By automating this process, users can efficiently gather and organize match statistics, facilitating deeper insights and informed decision-making in the realm of football analysis.

Pre-requisites

  • Python 3.10
  • Selenium 4.20.0
  • Plotly 5.21.0
  • ChromeDriver for macOS arm64, version 124.0.6367.91
  • Chrome browser version 124.0.6367.93 (Official Build) (arm64)

Up and Running

alt text

cd into project root

% python main.py

INFO:__main__:Navigating to https://www.adamchoi.co.uk/overs/detailed...
INFO:__main__:Selecting 'All matches'...
INFO:__main__:Selecting country: 'Spain'...
INFO:__main__:Selecting season: '23/24'...
INFO:__main__:Extracting match data...
INFO:__main__:Transforming match data...
INFO:__main__:Loading match data into matches_20240428163935.csv
INFO:__main__:Computing team stats...
INFO:__main__:Displaying team stats...
INFO:__main__:Exiting program...

Sample Output matches_20240428163935.csv

...
date,home_team,score,away_team,result
14-08-2023,Cadiz,1 - 0,Alaves,Cadiz
21-08-2023,Alaves,4 - 3,Sevilla,Alaves
28-08-2023,Getafe,1 - 0,Alaves,Getafe
02-09-2023,Alaves,1 - 0,Valencia,Alaves
15-09-2023,Vallecano,2 - 0,Alaves,Vallecano
22-09-2023,Alaves,0 - 2,Ath Bilbao,Ath Bilbao
28-09-2023,Celta,1 - 1,Alaves,draw
01-10-2023,Alaves,0 - 2,Osasuna,Osasuna
08-10-2023,Alaves,1 - 1,Betis,draw
22-10-2023,Villarreal,1 - 1,Alaves,draw
29-10-2023,Ath Madrid,2 - 1,Alaves,Ath Madrid
...

Sample output team_stats_20240428163935.html

demo_stats

Troubleshooting

If you encounter issues with opening ChromeDriver on macOS Catalina, you can refer to the solution provided here: https://stackoverflow.com/questions/60362018/macos-catalinav-10-15-3-error-chromedriver-cannot-be-opened-because-the-de

Tip!

Press p or to see the previous file or, n or to see the next file

About

Automated Football Score Tracking: Using Selenium and Python Web Scraping to Identify Top Performing Teams.

Collaborators 1

Comments

Loading...