Skip to content

Instantly share code, notes, and snippets.

@lmiller1990
Created August 23, 2018 14:06
Show Gist options
  • Save lmiller1990/cc113a46b276714e9fa283626f7869d4 to your computer and use it in GitHub Desktop.
Save lmiller1990/cc113a46b276714e9fa283626f7869d4 to your computer and use it in GitHub Desktop.
stats['wins'] = []
for team in teams:
stats['wins'].append(team_games(df, team).result.sum())
result = pd.DataFrame(stats, index=teams)
print(result.sort_values(by='wins', ascending=False))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment