Skip to content

Instantly share code, notes, and snippets.

@rafa-acioly
Created September 17, 2024 23:23
Show Gist options
  • Save rafa-acioly/f21135d74f2c4a13cd21bdaeb3cc88ff to your computer and use it in GitHub Desktop.
Save rafa-acioly/f21135d74f2c4a13cd21bdaeb3cc88ff to your computer and use it in GitHub Desktop.
change_column_types.py
for column_name in df.columns:
defined_type = column_types[column_name]
if defined_type == 'int':
df[column_name] = df[column_name].astype(int)
# e por aí vai...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment