Skip to content Skip to sidebar Skip to footer

How To Do Sentiment Analysis Of Headlines With Textblob And Python

I want to calculate the polarity and subjectivity for some headlines that I have. My code works fine, it does not gives any error but for some rows it gives result 0.00000 for pola

Solution 1:

its sometimes happen. Try to use polarity method from polyglot. https://polyglot.readthedocs.io/en/latest/Installation.html

and compare results. Firstly you should make some preprocessing like:

  • remove stopwords
  • remove numbers, html links, numbers, special characters etc

Post a Comment for "How To Do Sentiment Analysis Of Headlines With Textblob And Python"