From 63291722404f5ecda8b3e9c0ec2a3b3f8d7684b6 Mon Sep 17 00:00:00 2001
From: Lennard Geese <lennard.geese@sva.de>
Date: Wed, 16 Apr 2025 17:18:52 +0200
Subject: [PATCH] Implement isWet()

---
 DataAnalyser.py | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/DataAnalyser.py b/DataAnalyser.py
index 1ff857a..fa89798 100644
--- a/DataAnalyser.py
+++ b/DataAnalyser.py
@@ -1,4 +1,5 @@
 import re
+import string
 
 import pandas as pandas
 from fastf1.core import Session, Lap, Laps, DataNotLoadedError
@@ -119,6 +120,12 @@ class DataAnalyser(DataHandler):
 
     # ===== Weather =====
 
+    def isWet(self, weatherDescription: string):
+        keywords: list[string] = ["rain", "wet"]
+        for keyword in keywords:
+            if keyword in weatherDescription.lower(): return True
+        return False
+
     def extractWeatherFromHtml(self, rawHtml):
         """
         Extract an events weather conditions from its respective wikipedia page.
-- 
GitLab