Skip to content

Instantly share code, notes, and snippets.

@abhishek-shrm
Created April 10, 2020 12:25
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 abhishek-shrm/552695cf25609accc55f222614ee0a10 to your computer and use it in GitHub Desktop.
Save abhishek-shrm/552695cf25609accc55f222614ee0a10 to your computer and use it in GitHub Desktop.
df['reading_time']=df['reviews.text'].apply(lambda x: textstat.reading_time(x))
print('Reading Time of upvoted reviews=>',df[df['reviews.numHelpful']>1]['reading_time'].mean())
print('Reading Time of not upvoted reviews=>',df[df['reviews.numHelpful']<=1]['reading_time'].mean())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment