Skip to content

This proposed code is useful to analyse sentiments from twitter comments using Twitter API

Notifications You must be signed in to change notification settings

Samery00/Opinion-Mining-twitter-sentiment-Analysis-

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Opinion-Mining-twitter-sentiment-Analysis-

This proposed code is useful to analyse sentiments from twitter comments using Twitter API.

Sentiment Analysis is the process of ‘computationally’ determining whether a piece of writing is positive, negative or neutral.

requirements:

Tweepy: tweepy is the python client for the official Twitter API. use this command to install using pip : pip install tweepy

TextBlob: textblob is the python library for processing textual data. use this : pip install textblob

NLTK is installed when textblob installation is done

Now , we need to fetch tweets through Twitter API, one needs to register an App through their twitter account. Follow these steps to do so :

  • go to https://developer.twitter.com/en/apps and click the button: ‘Create New App’
  • Fill the details.
  • Open the ‘Keys and Access Tokens’ tab.
  • And Copy ‘Consumer Key’, ‘Consumer Secret’, ‘Access token’ and ‘Access Token Secret’, then replace in the code.

Results:

Positive comments :

Image of the first tree

Negative Comments :

Image of the first tree

About

This proposed code is useful to analyse sentiments from twitter comments using Twitter API

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages