Skip to content

Instantly share code, notes, and snippets.

@kurasaiteja
Created July 7, 2020 08:12
Show Gist options
  • Save kurasaiteja/de5956dbea67ccdf8b4a37d2a8eea93f to your computer and use it in GitHub Desktop.
Save kurasaiteja/de5956dbea67ccdf8b4a37d2a8eea93f to your computer and use it in GitHub Desktop.
messages_df['Letter_Count'] = messages_df['Message'].apply(lambda s : len(s))
messages_df['Word_Count'] = messages_df['Message'].apply(lambda s : len(s.split(' ')))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment