|
| 1 | +--- |
| 2 | +title: "Case Study: Cricket Analytics, the game changer!" |
| 3 | +sidebar: false |
| 4 | +--- |
| 5 | + |
| 6 | +{{< figure src="/images/content_images/cs/ipl-stadium.png" |
| 7 | + caption="**IPLT20, the biggest Cricket Festival in India**" |
| 8 | + alt="Indian Premier League Cricket cup and stadium" |
| 9 | + attr="*(Image credits: IPLT20 (cup and logo) & Akash Yadav (stadium))*" |
| 10 | + attrlink="https://unsplash.com/@aksh1802" >}} |
| 11 | + |
| 12 | +<blockquote cite="https://www.scoopwhoop.com/sports/ms-dhoni/"> |
| 13 | + <p>You don't play for the crowd, you play for the country.</p> |
| 14 | + <footer align="right">—M S Dhoni, <cite>International Cricket Player, ex-captain, Indian Team, plays for Chennai Super Kings in IPL</cite></footer> |
| 15 | +</blockquote> |
| 16 | + |
| 17 | +## About Cricket |
| 18 | + |
| 19 | +It would be an understatement to state that Indians love cricket. The game is |
| 20 | +played in just about every nook and cranny of India, rural or urban, popular |
| 21 | +with the young and the old alike, connecting billions in India unlike any other sport. |
| 22 | +Cricket enjoys lots of media attention. There is a significant amount of |
| 23 | +[money](https://www.statista.com/topics/4543/indian-premier-league-ipl/) and |
| 24 | +fame at stake. Over the last several years, technology has literally been a game |
| 25 | +changer. Audiences are spoilt for choice with streaming media, tournaments, |
| 26 | +affordable access to mobile based live cricket watching, and more. |
| 27 | + |
| 28 | +The Indian Premier League (IPL) is a professional Twenty20 cricket |
| 29 | +league, founded in 2008. It is one of the most attended cricketing events in |
| 30 | +the world, valued at [$6.7 billion](https://en.wikipedia.org/wiki/Indian_Premier_League) |
| 31 | +in 2019. |
| 32 | + |
| 33 | +Cricket is a game of numbers - the runs scored by a batsman, the wickets taken |
| 34 | +by a bowler, the matches won by a cricket team, the number of times a batsman |
| 35 | +responds in a certain way to a kind of bowling attack, etc. The capability to |
| 36 | +dig into cricketing numbers for both improving performance and studying |
| 37 | +the business opportunities, overall market and economics of cricket via powerful |
| 38 | +analytics tools, powered by numerical computing software such as NumPy, is a big |
| 39 | +deal. Cricket analytics provides interesting insights into the game and |
| 40 | +predictive intelligence regarding game outcomes. |
| 41 | + |
| 42 | +Today, there are rich and almost infinite troves of cricket game records and |
| 43 | +statistics available, e.g., [ESPN |
| 44 | +cricinfo](https://stats.espncricinfo.com/ci/engine/stats/index.html) and |
| 45 | +[cricsheet](https://cricsheet.org). These and several such cricket databases |
| 46 | +have been used for [cricket |
| 47 | +analysis](https://www.researchgate.net/publication/336886516_Data_visualization_and_toss_related_analysis_of_IPL_teams_and_batsmen_performances) |
| 48 | +using the latest machine learning and predictive modelling algorithms. |
| 49 | +Media and entertainment platforms along with professional sports bodies |
| 50 | +associated with the game use technology and analytics for determining key |
| 51 | +metrics for improving match winning chances: |
| 52 | + |
| 53 | +* batting performance moving average, |
| 54 | +* score forecasting, |
| 55 | +* gaining insights into fitness and performance of a player against different opposition, |
| 56 | +* player contribution to wins and losses for making strategic decisions on team composition |
| 57 | + |
| 58 | +{{< figure src="/images/content_images/cs/cricket-pitch.png" |
| 59 | + class="csfigcaption" |
| 60 | + caption="**Cricket Pitch, the focal point in the field**" |
| 61 | + alt="A cricket pitch with bowler and batsmen" |
| 62 | + align="middle" |
| 63 | + attr="*(Image Credits: Debarghya Das)*" |
| 64 | + attrlink="http://debarghyadas.com/files/IPLpaper.pdf" >}} |
| 65 | + |
| 66 | +### Key Data Analytics Objectives |
| 67 | + |
| 68 | +* Sports data analytics are used not only in cricket but many [other |
| 69 | + sports](https://adtmag.com/blogs/dev-watch/2017/07/sports-analytics.aspx) for |
| 70 | + improving the overall team performance and maximize winning chances. |
| 71 | +* Real-time data analytics can help in gaining insights even during the game |
| 72 | + for changing tactics by the team and by associated businesses for economic |
| 73 | + benefits and growth. |
| 74 | +* Besides historical analysis, predictive models are |
| 75 | + harnessed to determine the possible match outcomes that require significant |
| 76 | + number crunching and data science know-how, visualization tools and capability |
| 77 | + to include newer observations in the analysis. |
| 78 | + |
| 79 | +{{< figure src="/images/content_images/cs/player-pose-estimator.png" |
| 80 | + class="fig-center" |
| 81 | + alt="pose estimator" |
| 82 | + caption="**Cricket Pose Estimator**" |
| 83 | + attr="*(Image Credits: connect.vin)*" |
| 84 | + attrlink="https://connect.vin/2019/05/ai-for-cricket-batsman-pose-analysis/" >}} |
| 85 | + |
| 86 | +### The Challenges |
| 87 | + |
| 88 | +* **Data Cleaning and preprocessing** |
| 89 | + |
| 90 | + IPL has expanded cricket beyond the classic test match format to a much |
| 91 | + larger scale. The number of matches played every season across various |
| 92 | + formats has increased and so has the data, the algorithms, newer sports data |
| 93 | + analysis technologies and simulation models. Cricket data analysis requires |
| 94 | + field mapping, player tracking, ball tracking, player shot analysis and |
| 95 | + several other aspects involved in how the ball is delivered, its angle, spin, |
| 96 | + velocity and trajectory. All these factors together have increased the |
| 97 | + complexity of data cleaning and preprocessing. |
| 98 | + |
| 99 | +* **Dynamic Modeling** |
| 100 | + |
| 101 | + In cricket, just like any other sport, |
| 102 | + there can be a large number of variables related to tracking various numbers |
| 103 | + of players on the field, their attributes, the ball and several possibilities |
| 104 | + of potential actions. The complexity of data analytics and modeling is |
| 105 | + directly proportional to the kind of predictive questions that are put forth |
| 106 | + during analysis and are highly dependent on data representation and the |
| 107 | + model. Things get even more challenging in terms of computation, data |
| 108 | + comparisons when dynamic cricket play predictions are sought such as what |
| 109 | + would have happened if the batsman had hit the ball at a different angle or |
| 110 | + velocity. |
| 111 | + |
| 112 | +* **Predictive Analytics Complexity** |
| 113 | + |
| 114 | + Much of the decision making in Cricket is based on questions such as "how |
| 115 | + often does a batsman play a certain kind of shot if the ball delivery is of a |
| 116 | + particular type", or "how does a bowler change his line and length if the |
| 117 | + batsman responds to his delivery in a certain way". |
| 118 | + This kind of predictive analytics query requires highly granular dataset |
| 119 | + availability and the capability to synthesize data and create generative |
| 120 | + models that are highly accurate. |
| 121 | + |
| 122 | +## NumPy’s Role in Cricket Analytics |
| 123 | + |
| 124 | +Sports Analytics is a thriving field. Many researchers and companies |
| 125 | +[use NumPy](https://adtmag.com/blogs/dev-watch/2017/07/sports-analytics.aspx) |
| 126 | +and other PyData packages like Scikit-learn, SciPy, Matplotlib, and Jupyter. |
| 127 | +in addition to latest machine learning and AI techniques. NumPy has been used |
| 128 | +for various kinds of cricket related sporting analytics such as: |
| 129 | + |
| 130 | +* **Statistical Analysis:** NumPy's numerical capabilities help estimate the |
| 131 | + statistical significance of observational data or match events in the context |
| 132 | + of various player and game tactics, estimating the game outcome by comparison |
| 133 | + with a generative or static model. |
| 134 | + [Causal analysis](https://amplitude.com/blog/2017/01/19/causation-correlation) |
| 135 | + and [big data approaches](https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4996805/) |
| 136 | + are used for tactical analysis. |
| 137 | + |
| 138 | +* **Data Visualization:** Data graphing and [visualization](https://towardsdatascience.com/advanced-sports-visualization-with-pandas-matplotlib-and-seaborn-9c16df80a81b) |
| 139 | + provides useful insights into relationship between various datasets. |
| 140 | + |
| 141 | +## Summary |
| 142 | + |
| 143 | +Sports Analytics have changed the way professional games are played, especially |
| 144 | +regarding decision making which was until recently primarily done based on |
| 145 | +“gut feeling" or adherence to past traditions. NumPy forms a |
| 146 | +solid foundation for a large set of Python packages which provide higher level |
| 147 | +functions related to data analytics, machine learning and AI algorithms. These |
| 148 | +packages are widely deployed to gain real-time insights that help in decision |
| 149 | +making for game-changing outcomes, both on field as well as to draw inferences |
| 150 | +and drive business around the game of cricket. Finding out the hidden |
| 151 | +parameters, patterns and attributes that lead to the outcome of a cricket match |
| 152 | +helps the stakeholders to take notice of game insights that are otherwise hidden |
| 153 | +in numbers and statistics. |
| 154 | + |
| 155 | +{{< figure src="/images/content_images/cs/numpy_ca_benefits.png" |
| 156 | + class="fig-center" |
| 157 | + alt="Diagram showing benefits of using NumPy for cricket analytics" |
| 158 | + caption="**Key NumPy Capabilities utilized**" >}} |
0 commit comments