Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save wibowotangara/7d18d2d5b62912a1da1434f015797aef to your computer and use it in GitHub Desktop.
Save wibowotangara/7d18d2d5b62912a1da1434f015797aef to your computer and use it in GitHub Desktop.
for col in df.select_dtypes(include='object').columns.tolist():
value_counts_percentage = df[col].value_counts(normalize=True) * 100
if any(value_counts_percentage > 80):
print(value_counts_percentage)
print('\n')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment