Skip to content

Instantly share code, notes, and snippets.

@AayushSameerShah
Last active May 23, 2021 06:10
Show Gist options
  • Save AayushSameerShah/c3ff97545c39348af0d8f7aac9d03e43 to your computer and use it in GitHub Desktop.
Save AayushSameerShah/c3ff97545c39348af0d8f7aac9d03e43 to your computer and use it in GitHub Desktop.
This is the second version of pandas usefuls... enjoy
# 1. Describe... some more
DF.describe(include= ['dtype'])
# 2. Use the freaking .str.contains()
DF.col.str.contains()
# 3. Format for a while! (COOLEST)
pd.set_option('display.float_format', '{:,}'.format)
# See all options by
pd.describe_option()
# 4. Drop multiple rows
DF.drop(df.index[:100])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment