I am looking to get calculate the field in my data from Home Team Home Games Count.
I've created the function below but know it isn't right. I then want to apply it to my table as below.
Any help is greatly appreciated
def home_team_home_games(row): row.Home_Team return count.Home_team df['home_team_home_games_count'] = df.apply(home_team_home_games, axis=1)
|HomeTeam||Away Team||Home Team Home Games Count|