Tutorial - Rolling Average Across Matches

Hi all,

Today I am going to focus more on a calculation rather than the visual. For this video, I will focus on a rolling average across matches, rather than days. This requires an extra step to calculate an index value for the match date. In a future video I will show a different method for doing this as well for different types of data.

As always, subscribe here for more videos and to Power Performance Through Data.


Import Notes for Calculated Columns

There are a few important things to keep in mind when working with calculated columns.

  1. Columns are calculated on data load and so cause your model to load slower, depending on the size of your data model.
    1. Some good information is provided by @notaboutthecell on Twitter who published this presentation on his github which covers it excellently.
  2. Because the column is calculated on load, adding a dynamic value to the calculation is not possible. Such as changing the rolling match period.
    1. This is possible using a measure and I will provide a video for this in the future.

Hope this video was insightful and helps you to create your rolling averages.

Thanks!

Josh Trewin
Josh Trewin
Data Scientist

I’m a data scientist, learning my way through R / Python and applying to football data from StatsBomb, provided for free through GitHub. Follow my journey on here or Twitter to find out when I add new content.

comments powered by Disqus

Related