Skip to content

Instantly share code, notes, and snippets.

@StrikingLoo
Last active September 10, 2018 22:58
Show Gist options
  • Select an option

  • Save StrikingLoo/6f3b245959c6105d51913c322d101dd8 to your computer and use it in GitHub Desktop.

Select an option

Save StrikingLoo/6f3b245959c6105d51913c322d101dd8 to your computer and use it in GitHub Desktop.
total_rows = df.shape[0]
unique_athletes = len(df.Name.unique())
medal_winners = len(df[df.Medal.fillna('None')!='None'].Name.unique())
"{0} {1} {2}".format(total_rows, unique_athletes, medal_winners)
#'271116 134732 28202'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment