Skip to content

Instantly share code, notes, and snippets.

@ericgitonga
Created May 25, 2021 10:08
Show Gist options
  • Save ericgitonga/56e747bd32cbc8a927191cf9e8a19787 to your computer and use it in GitHub Desktop.
Save ericgitonga/56e747bd32cbc8a927191cf9e8a19787 to your computer and use it in GitHub Desktop.
Code to change City name to Unknown
df.loc[df['State'].isnull(), 'City'] = 'Unknown'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment