Skip to content

Instantly share code, notes, and snippets.

@AlexDel
Last active February 12, 2019 03:54
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 AlexDel/9fb44bee346470916d7e895a9e6fafae to your computer and use it in GitHub Desktop.
Save AlexDel/9fb44bee346470916d7e895a9e6fafae to your computer and use it in GitHub Desktop.
vkDataFrame = getVkData()
vkDataFrame['unreliableSpeech_ratio'] = vkDataFrame['normal_tokens'].apply(CountFearFeatures_unreliableSpeech)
vkGrouped = vkDataFrame.groupby('emotion')[['unreliableSpeech_ratio']].agg('mean')
print(vkGrouped)
# emotion
# ANGER 0.000646
# DISGUST 0.000383
# DISTRESS 0.000217
# ENJOYMENT 0.000232
# EXCITEMENT 0.000562
# FEAR 0.000417
# SHAME 0.000522
# STARTLE 0.000577
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment