/formula1-dataanalysis

This repository contains a collection of Jupyter notebooks that I have created to analyze Formula 1 data. The notebooks cover a wide range of topics, including race results, driver performance, and car performance. On top of that, I have created a number of visualizations to help illustrate my findings.

Primary LanguageJupyter Notebook

Formula 1 Data Analysis

This repository contains a collection of Jupyter notebooks that I have created to analyze Formula 1 data. The notebooks cover a wide range of topics, including race results, driver performance, and car performance. On top of that, I have created a number of visualizations to help illustrate my findings. The data that I used to analyze are all from FastF1, you may find their project HERE.

Getting Started

To get started, you will need to install Jupyter Notebooks. Once you have installed Jupyter Notebooks, you can clone this repository and open the notebooks in Jupyter Notebooks.

To setup the enviroment using Anaconda:

conda create --name f1 --file requirements.txt
conda activate f1

To setup using Docker:

docker pull edmundhong/formula1-dataanalysis
docker run -p 8888:8888 edmundhong/formula1-dataanalysis

Notebooks

The notebooks in this repository are divided into the following categories:

  • Best Lap Analysis

This is used to analyze single lap performance such as Qualifying, Free Practices and Sprint Shootout. It will only focus on the fastest lap that made by drivers instead of the overall race pace.

  • Race Analysis

This is used to analyze the Sunday race or Sprint Race and will focus more on the general race pace, tyre degration, team strategy and pit stops.

Me & F1

I had never been a fan of Formula 1 before. I didn't understand the appeal of watching cars drive around in circles for hours on end. But then, I saw the crash. It was the 2022 British Grand Prix, and Zhou Guanyu was involved in a horrific accident. His car flipped over and went flying through the air, before landing upside down on the barriers. I watched in horror as the medical team rushed to his aid.

But then, the unthinkable happened. Zhou got out of the car on his own. He was shaken up, but he was okay. I was shocked that he came out unscathed after the tragedy. That crash changed everything for me. I quickly learned that the safety of Formula 1 has evolved over the years including the Halo that protected him, it was at the moment I realized that Formula 1 wasn't just about cars driving around in circles.

I started watching Formula 1 every weekend after that. I learned about the history of the sport, the different teams and drivers, and the technical aspects of the cars. I even started to follow the drivers on social media. From the Venturi Tunnel or Ground Effects floor that developed by Adrian Newey from Redbull, to the Mercesdes' DAS system, I quickly fell in love with Formula 1. It's an amazing sport, and I'm so glad that I gave it a chance.

Here are some of the things that I love about Formula 1:

  • The drivers are incredibly talented and skilled. They have to be in order to race at these speeds and in these conditions.
  • The races are always exciting and unpredictable. There's always a chance for a surprise, and that's what makes them so much fun to watch.
  • The technology is incredible. The cars are so fast and advanced, and it's amazing to see what the engineers are able to do just to improve the car by a few tenths.
  • If you're looking for a new sport to watch, I highly recommend Formula 1. It's an amazing sport with something for everyone.

Contributing

If you would like to contribute to this repository, please feel free to fork the repository and submit a pull request.

Notice

I am unofficial and not associated in any way with the Formula 1 companies. F1, FORMULA ONE, FORMULA 1, FIA FORMULA ONE WORLD CHAMPIONSHIP, GRAND PRIX and related marks are trade marks of Formula One Licensing B.V.