Created
November 2, 2020 03:22
-
-
Save Rafastoievsky/7ac2fae8717904db1f6c00b1963cb5ab to your computer and use it in GitHub Desktop.
Whatsapp group chat analysis: create new emojis column from messeges
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
| def split_count(text): | |
| emoji_list = [] | |
| data = regex.findall(r'\X', text) | |
| for word in data: | |
| if any(char in emoji.UNICODE_EMOJI for char in word): | |
| emoji_list.append(word) | |
| return emoji_list | |
| chat["emoji"] = chat["Message"].apply(split_count) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment