fbref¶
fbref.fbrefPlayer¶
get_player_aggregate_stats¶
-
fbrefPlayer.get_player_aggregate_stats(type, competition='dom_lg')¶ get aggregate career statistics of player.
- Parameters
type (str) –
this is the type of statistics that are to be fetched. Possible values:
standard
shooting
passing
passing_types
goal_shot_creation
defensive_actions
possession
playing_time
miscellaneous
competition (str) –
the competition for which stats are to be fetched. Possible values:
all_competitions
domestic_league
domestic_cup
internationl_cup
national_team
- Returns
the aggregate career statistics for the given league and stat type
- Return type
dict
get_player_season_stats¶
-
fbrefPlayer.get_player_season_stats(type, season)¶ get statistics for a particular season of a player.
- Parameters
type (str) –
this is the type of statistics that are to be fetched. Possible values:
summary
passing
passing_types
gca (Goal and Shot Creation)
defense (Defensive Actions)
possession
misc
season (int) – the season for which data is needed. For the 2020/21 season, enter 2020.
- Returns
the given season’s and stat type of the player
- Return type
dict
fbref.fbrefTeam¶
get_team_competition_names¶
-
fbrefTeam.get_team_competition_names(season)¶ get the competitions which team is involved in for a given season
- Parameters
season (int) – the season for which data is needed. For the 2020/21 season, enter 2020.
- Returns
the competition name and corresponding ID’s
- Return type
dict
get_team_aggregate_stats¶
-
fbrefTeam.get_team_aggregate_stats(season, comp_id, type='scores_and_fixtures')¶ get the statistics of team in a given season and competition.
- Parameters
season (int) – the season for which data is needed. For the 2020/21 season, enter 2020.
comp_id – the id of the competition for which data is required. to get appropriate competition_id’s
use the get_team_competition_names for a given season. :type comp_id: str
- Returns
the competition name and corresponding ID’s
- Return type
dict