Ipl Data Analysis 2008 To 2022
IPL Data Analysis (2008 - 2022)
Indian Premier League (IPL), one of the most celebrated sports league across the globe. It is a professional cricket league held annually with city based franchise teams. It brings with itself great thrill and entertainment featuring world class players from all over the globe. The teams are owned by different celebrities, businessmen, and investors, and they bid for players in an auction before the start of the tournament. It is not just a regular cricket match where the teams are contesting to win the game but a plethora of entertainment, emotions, people's love for the game and a great experience for the fans who watch their favorite players belonging to different countries coming together or against it each other in the league.
However, as much as the
IPL is a great source of entertainment, it also has significant impact in India's economy as it is administered by
Board of Control for Cricket in India (BCCI). It generates lots of revenue through various channels like through broadcasting rights, sponsorships, and merchandise sales which in turn creates jobs and boosts overall economy.
With the IPL season going on, I found it relevant to try my hands on analyzing IPL data which I got from https://www.kaggle.com/ . Here is the link to the dataset that I have used: https://www.kaggle.com/datasets/vora1011/ipl-2008-to-2021-all-match-dataset?select=IPL_Matches_2008_2022.csv .
The dataset has two files, one which contains the match data and the other has the ball by ball data of all the matches. The match dataset has details like the venue, dates, winner, best player and the teams contesting. The ball by ball dataset as understood by the names has the details like the run scored, extra run scored, wicket taken for every ball of each match. The idea is to merge the datasets into one with all the required details for making an analysis for each season of
IPL. Further, to execute all of this I will be using all the knowledge that I have gained from the Data Analysis tutorial by
Akash N S on https://jovian.com/ platform.
Here's, the link for the course by
Akash N S: [Data Analysis with Python: Zero to Pandas]https://jovian.com/outlink?url=zerotopandas.com
How to run the code
This is an executable Jupyter notebook hosted on Jovian.ml, a platform for sharing data science projects. You can run and experiment with the code in a couple of ways: using free online resources (recommended) or on your own computer.
Option 1: Running using free online resources (1-click, recommended)
The easiest way to start executing this notebook is to click the "Run" button at the top of this page, and select "Run on Binder". This will run the notebook on mybinder.org, a free online service for running Jupyter notebooks. You can also select "Run on Colab" or "Run on Kaggle".
Option 2: Running on your computer locally
Install Conda by following these instructions. Add Conda binaries to your system
PATH, so you can use the
condacommand on your terminal.
Create a Conda environment and install the required libraries by running these commands on the terminal:
conda create -n zerotopandas -y python=3.8 conda activate zerotopandas pip install jovian jupyter numpy pandas matplotlib seaborn opendatasets --upgrade
- Press the "Clone" button above to copy the command for downloading the notebook, and run it on the terminal. This will create a new directory and download the notebook. The command will look something like this:
jovian clone notebook-owner/notebook-id
- Enter the newly created directory using
cd directory-nameand start the Jupyter notebook.
You can now access Jupyter's web interface by clicking the link that shows up on the terminal or by visiting http://localhost:8888 on your browser. Click on the notebook file (it has a
.ipynb extension) to open it.
Downloading the Dataset
Downloading the dataset from https://www.kaggle.com/
!pip install jovian opendatasets --upgrade --quiet