CoolFace
Datasetpublic

Maiyarasu/football_analytics

⚽ Football Analytics Database Overview This dataset contains a processed SQLite database generated from StatsBomb Open Data. The objective of this dataset is to provide a ready-to-use relational database for football analytics, eliminating the need to parse and transform thousands of raw JSON files. The database was created as part of the Football Analytics Dashboard project and is intended for: Football Analytics Sports Data Science SQL Practice Data Engineering… See the full description on the dataset page: https://huggingface.co/datasets/Maiyarasu/football_analytics.

sourceHugging Facemitupdated 1mo agoView on Hugging Face
3likes193downloads
Dataset Card

⚽ Football Analytics Database

Overview

This dataset contains a processed SQLite database generated from StatsBomb Open Data.

The objective of this dataset is to provide a ready-to-use relational database for football analytics, eliminating the need to parse and transform thousands of raw JSON files.

The database was created as part of the Football Analytics Dashboard project and is intended for:

  • Football Analytics
  • Sports Data Science
  • SQL Practice
  • Data Engineering Projects
  • Dashboard Development
  • Machine Learning Research

📊 Dataset Information

AttributeValue
FormatSQLite Database
Filefootball.db
Database Size~290 MB
Tables47
SourceStatsBomb Open Data
Database EngineSQLite
ProjectFootball Analytics Dashboard

🗂 Dataset Contents

The database contains structured football data including:

Competitions

  • Competition Information
  • Season Information
  • Tournament Metadata

Matches

  • Match Details
  • Match Dates
  • Home Team
  • Away Team
  • Match Outcomes

Teams

  • Team Information
  • Team Identifiers

Players

  • Player Information
  • Positions
  • Team Associations

Events

Detailed event-level football data including:

  • Passes
  • Shots
  • Dribbles
  • Carries
  • Duels
  • Interceptions
  • Fouls
  • Clearances
  • Blocks
  • Goalkeeper Actions
  • Substitutions
  • Possessions

🏗 Database Schema

The database follows a normalized relational structure.

text
Competitions
    │
    └── Seasons
            │
            └── Matches
                    │
                    ├── Events
                    │       ├── PassEvents
                    │       ├── ShotEvents
                    │       ├── GoalkeeperEvents
                    │       ├── DribbleEvents
                    │       └── Other Event Tables
                    │
                    ├── Teams
                    │
                    └── Players

The complete ER Diagram is available in the GitHub repository.


💻 Example Queries

Top Goal Scorers

sql
SELECT
    p.player_name,
    COUNT(*) AS goals
FROM Players p
JOIN Events e
    ON p.player_id = e.player_id
JOIN ShotEvents se
    ON e.event_id = se.event_id
JOIN ShotOutcomes so
    ON se.shot_outcome_id = so.shot_outcome_id
WHERE so.shot_outcome_name = 'Goal'
GROUP BY p.player_id
ORDER BY goals DESC;

Pass Completion Percentage

sql
SELECT
    p.player_name,
    COUNT(CASE WHEN pe.pass_outcome_id IS NULL THEN 1 END) AS completed_passes,
    COUNT(*) AS total_passes,
    ROUND(
        100.0 *
        COUNT(CASE WHEN pe.pass_outcome_id IS NULL THEN 1 END)
        / COUNT(*),
        2
    ) AS completion_percentage
FROM Players p
JOIN Events e
    ON p.player_id = e.player_id
JOIN PassEvents pe
    ON e.event_id = pe.event_id
GROUP BY p.player_id;

🚀 Usage

Python

python
import sqlite3
import pandas as pd

conn = sqlite3.connect("football.db")

df = pd.read_sql(
    "SELECT * FROM Matches LIMIT 10",
    conn
)

print(df.head())

SQLite

bash
sqlite3 football.db

Example:

sql
SELECT COUNT(*) FROM Matches;

⚽ Source Data

This database was generated from:

StatsBomb Open Data

Repository:

https://github.com/statsbomb/open-data

Please review StatsBomb's licensing terms before commercial use.


🌐 Related Project

Football Analytics Dashboard

GitHub Repository:

https://github.com/vishnu8406/football-analytics

Live Dashboard:

https://football-analytics-maiyarasu.streamlit.app/


🎯 Intended Use

This dataset is suitable for:

  • Football Analytics
  • SQL Learning
  • Sports Data Science
  • Data Engineering Projects
  • Dashboard Development
  • Academic Research
  • Machine Learning Feature Engineering

📖 Citation

If you use this dataset in research or projects, please cite:

text
Vishnu S. Maiyarasu.
Football Analytics Database.
Generated from StatsBomb Open Data.
2026.

🙏 Acknowledgements

  • StatsBomb Open Data
  • SQLite
  • Python
  • Pandas
  • Streamlit
  • mplsoccer
  • Football Analytics Community

This dataset is provided for educational, research, and analytics purposes.