Skip to content

Instantly share code, notes, and snippets.

@Kamaldeep0077
Created November 8, 2020 21:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Kamaldeep0077/c1da746c27118f09a64cbc0aa48ac919 to your computer and use it in GitHub Desktop.
Save Kamaldeep0077/c1da746c27118f09a64cbc0aa48ac919 to your computer and use it in GitHub Desktop.
data['Outlet_Location_Type_Encoded'] = data['Outlet_Location_Type'] \
.replace({'Tier 1': 1, 'Tier 2': 2, 'Tier 3': 3})
data[['Outlet_Location_Type', 'Outlet_Location_Type_Encoded']].head()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment