Created
March 10, 2025 14:55
-
-
Save taniomi/ee635617b033fe7ee825bdec39dbe562 to your computer and use it in GitHub Desktop.
Easily replace values in the entire pandas dataframe
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| df.replace(to_replace='nan', value=None, inplace=True) | |
| df.replace(to_replace='[]', value=None, inplace=True) | |
| df.replace(to_replace='', value=None, inplace=True) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment