f1pystats package#
Submodules#
f1pystats.constructor_info module#
Contains all the functions used by get_constructors()
f1pystats.constructor_results module#
Contains all functions used by constructor_standings()
- class f1pystats.constructor_results.ConstructorResults(results)#
- Bases: - object- Contains all methods used to get constructor results - get_constructor_names()#
- Returns the constructor names 
 - get_constructor_nationality()#
- Returns the constructor nationality 
 - get_constructor_points()#
- Returns the constructor points 
 - get_constructor_positions()#
- Returns the constructor positions 
 - get_constructor_wins()#
- Returns the constructor wins 
 
f1pystats.driver_info module#
Contains all the functions used by get_driver()
- class f1pystats.driver_info.DriverInfo(info)#
- Bases: - object- This is the class which stores all the functions for get_driver - get_drivers_dob()#
- Returns the driver’s date of birth list 
 - get_drivers_names()#
- Returns the driver’s name list 
 - get_drivers_nationality()#
- Returns the list of driver’s nationality 
 - get_drivers_number()#
- Returns the list of driver’s number 
 
f1pystats.driver_results module#
Contains all functions used by driver_standings()
- class f1pystats.driver_results.DriverResults(results)#
- Bases: - object- Contains all methods used to get driver results - get_driver_names()#
- Returns the driver names 
 - get_driver_nationality()#
- Returns the driver’s nationality 
 - get_driver_points()#
- Returns the points obtained by each driver 
 - get_driver_positions()#
- Returns the driver positions 
 - get_driver_teams()#
- Returns the driver’s team name 
 - get_driver_wins()#
- Returns the total wins for each driver 
 
f1pystats.f1pystats module#
This module is responsible for handling the user-level function calls
- f1pystats.f1pystats.constructor_standings(year)#
- Returns the constructor standings for a specified year 
- f1pystats.f1pystats.conv_sec(duration)#
- Returns duration time converted to seconds. - The duration time format is “hh:mm:ss.sss”. hh, mm and fractional part can be omitted. - Return type:
- float
 - Examples - >>> conv_sec("58.79") # 1974 R9 Niki Lauda Qualify TIme 58.79 >>> conv_sec("1:33:56.736") # 2003 R1 Max Verstappen Race Time 5636.736 
- f1pystats.f1pystats.driver_standings(year)#
- Returns the driver standings for a specified year 
- f1pystats.f1pystats.fastest_laps(year, race_round)#
- Returns the fastest lap for a particular race 
- f1pystats.f1pystats.finishing_status(year, race_round=0)#
- Returns the finishing status for a year with a optional parameter of round 
- f1pystats.f1pystats.get_circuits(year=None)#
- Returns the circuit name, circuit locality and circuit country 
- f1pystats.f1pystats.get_constructors(year=None)#
- Returns a list of constructors for a specified year 
- f1pystats.f1pystats.get_drivers(year, round_num=None)#
- Returns a list of drivers for a specified year 
- f1pystats.f1pystats.lap_times(year, race_round, lap_number)#
- Returns the lap times for a specified year, race round and lap number 
- f1pystats.f1pystats.pit_stops(year, race_round, stop_number=0, fastest=False)#
- Returns the pit stops for a specific race in a season 
- f1pystats.f1pystats.qualifying_results(year, race_round)#
- Returns the driver name , driver position, driver number, constructor name , the 3 Q times 
- f1pystats.f1pystats.race_table(year)#
- Returns the race schedule for a specified year 
- f1pystats.f1pystats.race_winners(year)#
- Returns the race winners in a specified year 
- f1pystats.f1pystats.sprint_results(year, race_round)#
- Returns the sprint qualifying results for a year and round 
f1pystats.finishing_status module#
Contains all functions used by finishing_status()
f1pystats.lap_times module#
Contains all functions used by lap_times()
f1pystats.pit_stops module#
Contains all functions used by pit_stops()
- class f1pystats.pit_stops.PitStops(results)#
- Bases: - object- Contains all methods used to get the pit stop info - get_driver_names()#
- Returns a list of the driver names 
 - get_durations()#
- Returns the duration of each pitstop 
 - get_lap_numbers()#
- Returns a list of lap numbers 
 - get_stop_numbers()#
- Return the pitstop numbers 
 - get_times()#
- Returns a list of times 
 
f1pystats.qualifying_results module#
Contains all functions used by qualifying_results()
- class f1pystats.qualifying_results.QualifyingResults(results)#
- Bases: - object- Class which contains the methods which provide the details qualifying_results() - get_constructors()#
- Returns the list of name of the constructors 
 - get_driver_numbers()#
- Returns a list of driver numbers 
 - get_names()#
- Returns a list of driver names 
 - get_positions()#
- Returns a list of driver positions 
 - get_q1_times()#
- Returns a list of Q1 timings 
 - get_q2_times()#
- Returns a list of Q2 timings 
 - get_q3_times()#
- Returns a list of Q3 timings 
 
f1pystats.race_circuits module#
Contains all functions used by get_circuits()
- class f1pystats.race_circuits.RaceCircuits(results)#
- Bases: - object- Class which contains the methods which provide the details for get_circuits - get_circuit_country()#
- Returns a list of circuit country 
 - get_circuit_locality()#
- Returns a list of circuit locality 
 - get_circuit_name()#
- Returns a list of circuit names 
 
f1pystats.race_schedule module#
Contains all functions used by race_table()
- class f1pystats.race_schedule.RaceSchedule(schedule)#
- Bases: - object- Contains all methods used to get the race schedule - get_race_circuits()#
- Returns the race circuit names 
 - get_race_countries()#
- Returns the host country of each race 
 - get_race_locality()#
- Returns the local area hosting each race 
 - get_race_names()#
- Returns the race names 
 - get_race_round()#
- Returns the round number for each race 
 - get_race_schedule_dates()#
- Returns the race dates 
 - get_race_schedule_times()#
- Returns race times 
 
f1pystats.race_winners module#
Contains all functions used by race_winners()
- class f1pystats.race_winners.RaceWinners(results)#
- Bases: - object- Contains all methods used to get the race winners - get_grands_prix()#
- Returns a list of the grand prix names 
 - get_race_dates()#
- Returns a list containing the race dates 
 - get_race_laps()#
- Returns a list containing the number of laps in each race 
 - get_race_times()#
- Returns the length of each race 
 - get_race_winners()#
- Returns a list of the race winner names 
 - get_winner_start_positions()#
- Returns the winners starting position 
 - get_winning_constructors()#
- Returns a list of the winning constructor 
 
f1pystats.sprint_results module#
Contains all functions used by sprint_results()
- class f1pystats.sprint_results.SprintResults(results)#
- Bases: - object- Contains all the methods used to get sprint qualifying results - get_driver_grid()#
- Returns the driver sprint grid status 
 - get_driver_name()#
- Returns driver name 
 - get_driver_number()#
- Returns the driver number 
 - get_driver_points()#
- Returns the driver sprint points 
 - get_driver_pos()#
- Returns driver position 
 - get_driver_status()#
- Returns the driver sprint status 
 - get_driver_team()#
- Returns the driver team name 
 - get_driver_time()#
- Returns the driver sprint time 
 - get_laps()#
- Returns the driver sprint laps 
 
Module contents#
__init.py__ for f1pystats