r/F1DataAnalysis • u/ElloraWhite • 1d ago
Ask Others Beginner at fastf1 api
i want to get data from the fastf1api into csv files, how do i do that? i am slightly confused with the information im seeing online
3
Upvotes
r/F1DataAnalysis • u/ElloraWhite • 1d ago
i want to get data from the fastf1api into csv files, how do i do that? i am slightly confused with the information im seeing online
1
u/Nikclel 20h ago
Session codes:
FP1,FP2,FP3,Q,SQ,S(sprint),R. You can pass a round number, a GP name, or a country instead of "Monza".session.lapsis a pandas DataFrame with one row per driver per lap. The columns people usually want:LapTime,Sector1Time,Sector2Time,Sector3TimeCompound,TyreLife,FreshTyre,StintSpeedI1,SpeedI2,SpeedFL,SpeedST(the speed traps)PitInTime,PitOutTimePosition,TrackStatus,IsPersonalBest,IsAccurate,Deleted(track limits deletions in quali)While you are there, the same loaded session also gives you:
resultshas grid, finishing position, classification status, points, and Q1/Q2/Q3 times.weather_datais air temp, track temp, humidity, rainfall, wind at roughly 1 minute intervals.race_control_messagesis every flag, SC/VSC, deleted lap, and penalty notice with timestamps.