Skip to content

niftyNitin/Tweet-Sentiment-Analysis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

NLP Project

Sentiment Analysis of tweets

Dataset link is: https://www.kaggle.com/kazanova/sentiment140/download

Get twitter API credentials using the following steps:

  1. Create a twitter account.
  2. Go to https://apps.twitter.com/and log in with your Twitter user account.
  3. This step gives you a Twitter dev account under the same name as your user account.
  4. Click Create New App.
  5. Fill out the form, agree to the terms, and click Create your Twitter application.
  6. In the next page, click on Keys and Access Tokens tab, and copy your API key and API secret.
  7. Scroll down and click Create my access token, and copy your Access token and Access token secret.
  8. put the keys in twitter_credentials.py file.

Dataset contains 80,000 positive and negative data

Figure_1

Most common tokens used in the dataset

Figure_2

Text processing and tokenizing

text processing 1 text processing

Three different models are trained using different algorithms and their accuracy is compared

Linear SVC algorithm training and confusion matrix

linear svc Figure_Linearsvc

Logistic Regression training and confusion matrix

LR Figure_3

Bernaulli Naive Bayes training and confusion matrix

bernaulli Figure_bernaulli

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages