Skip to content

Instantly share code, notes, and snippets.

@mepsrajput
Last active April 14, 2022 14:48
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 mepsrajput/99ce9b5b592c1c5c18fea3bf9235b4ca to your computer and use it in GitHub Desktop.
Save mepsrajput/99ce9b5b592c1c5c18fea3bf9235b4ca to your computer and use it in GitHub Desktop.
datax = data['state'].value_counts().sort_index()
datay = pd.DataFrame({
'state': datax.index,
'Frequency': datax.values
})
datay
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment