socceranalysis.playerranking
¶
Module Contents¶
Functions¶
|
Returns a sorted table of players based on which variables the user decide to use to rank players. |
- socceranalysis.playerranking.rankingplayers(df, col_name)[source]¶
Returns a sorted table of players based on which variables the user decide to use to rank players. This function can help users find the most and less important variables which can be used to compare one player and the other in terms of performances.
- Parameters:
df (pandas dataframe) – The dataframe of the soccer dataset
col_name (str) – The name of the columns which the user decide to use to rank the players one
- Returns:
ranked_df – This is the sorted data frame by column name
- Return type:
pandas dataframe
Examples
>>> rankingplayers(soccer_df, "Goals_total", "Assists_Total")