This repository contains an interactive dashboard designed to provide an in-depth analysis of team performance, player contributions, and transfer strategies within the La Liga football league. The project uses R and Shiny to visualize various metrics and trends, offering insights to analysts, coaches, and fans alike.
-
DOCUMENTATION.docx
- Detailed project documentation, including the problem description, design process, and implementation details.
-
LALIGA_RSHINY.R
- Main R script for the Shiny dashboard implementation.
- Contains data preprocessing, interactive visualization components, and dashboard structure.
-
LaLiga_Stadiums.csv
- Dataset containing stadium locations for all La Liga teams.
-
combined_data_laliga.csv
- Core dataset with match results and performance statistics from 2014 to 2020.
-
primera-division.csv_2010_2020.csv
- Dataset with player transfer details from 2010 to 2020.
-
filtered_players_stats.csv
- Preprocessed dataset with player performance metrics.
-
player_id_mapping.csv
- Maps player IDs to their respective names.
-
season_mapping.csv
- Maps season IDs to season names, renaming "Primera Division" to "La Liga."
-
es_10km.shp
- Shapefile for visualizing geographical data on La Liga stadium locations.
The interactive dashboard is divided into five main tabs:
-
Introduction
- Overview of the project objectives and insights.
- Interactive introductory plot showcasing team performance metrics.
-
Teams Performance Dashboard
- Geographic and temporal analysis of team performance metrics (e.g., goals, wins, losses).
- Interactive map and bar chart for comparing teams across metrics and seasons.
-
Player Performance Dashboard
- Analysis of individual player statistics (e.g., goals, assists, dribbles).
- Focus on top-performing players and goalkeepers across seasons.
-
Transfers Dashboard
- Analysis of club spending and revenue in the transfer market.
- Highlights the top 10 transfers for the top 3 spending clubs.
-
Conclusion
- Summarizes key findings and provides recommendations.
- Install R and RStudio.
- Install required R packages using the following script (included in
LALIGA_RSHINY.R
):
necessary_packages <- c("shiny", "shinydashboard", "dplyr", "ggplot2", "lubridate", "readr", "tidyr", "stringr", "plotly", "sf", "leaflet", "ggrepel", "shinyjs")
for (package in necessary_packages) {
if (!requireNamespace(package, quietly = TRUE)) {
install.packages(package)
}
}
- Clone the repository:
git clone https://github.com/your-username/LaLiga-Dashboard.git
- Open
LALIGA_RSHINY.R
in RStudio. - Run the script to start the Shiny dashboard.
- Open the provided localhost URL in your browser to view the dashboard.
- Interactive Visualizations: Dropdowns, sliders, and tooltips for an engaging user experience.
- Geospatial Analysis: Choropleth maps showing team performance by region.
- Player Insights: Top performers in goals, assists, and goalkeeping.
- Financial Analysis: Detailed view of club spending and revenue in the transfer market.
Contributions are welcome! Feel free to submit pull requests for enhancements or bug fixes. Contact me at aadhikary252000@gmail.com
This project is licensed under GNU (General Public License). See the LICENSE file for details.