Sentiment Analysis
Table of Contents
2
Problem Definition
Introduction
Motivation
Literature Survey
Implementation
I
II
III
IV
V
VI
Algorithm taken to implement
VII Conclusion
VIII References
2
PROBLEM DEFINITION
Sentiment Analysis and Classification of Tweets
Using Classification Algorithms like Naive Bayes
and K-NN Algorithm.
2
In recent times, people have started using social media sites more often and it has become an
important aspect to analyze and find what they think about the content on social media and
what reactions they give. Data classification is the process of categorizing analyzed data to
make it more effective and productive. The classification's goal is to accurately predict the
target class for each and every case in the data. A classifier is basically an algorithm that is
specifically designed to implement classification. The data that is collected from the users
should be analysed and it should be properly processed and used for the identification of the
sentiments of the users. . The data set that we get from the users is very large and not all of it is
useful, proper selection and extraction of data needs to be done in order to separate out the
useful data.
I
INTRODUCTION
3
2
So, text mining is the process that is used for extraction of the useful data. It helps in getting the
exact information and meaningful data from the text. For applying the data mining algorithms
some processes need to be carried out, such as natural language processing or information
retrieval methods, or some pre-processing of text. .We will be using two classifiers for the
extraction of sentiments and thoughts of people based on what they share on Twitter and how
they respond to other people’s tweets and classify their tweets into categories. By comparing
the results of all two classifiers we will be able to find out which classifier gives the most
accurate result in terms of precision and accuracy
I
INTRODUCTION
4
2
MOTIVATION
For new technologies in this decade, we need a solution that
can create the perfect model to solve that particular problem.
The sentiments of the people are difficult to understand when
it comes to social media and hence it needs to be analyzed
and processed properly and accurately.
2
No. Techniques Summary limitations
1
Naïve Bayes algorithm
Naïve Bayes algorithm is
a classifier learning algorithm. It's
supported by the Bayes theorem and
used
for finding classification of datasets.
This algorithm faces the ‘zero-
frequency problem’ where it assigns
zero probability to a variable whose
category in the test data set wasn’t
available in the training dataset
2
KNN-precision
K-NN algorithm is
K-Nearest Neighbor and it checks for
the similarity between the new data
and
available data and puts our new case in
a category that best fits.
Accuracy
depends on the type of the data.
With
large data, the prediction stage might
become slow.
LITERATURE SURVEY
2
ALGORITHM
The two algorithms we have used to classify the tweets are:
• KNN Algorithm
• Naive Bayes Algorithm
KNN Algorithm:
K-NN algorithm is K-Nearest Neighbour and it checks for the similarity between the new
data and available data and puts our new case in a category that best fits. It mainly works on
the principle of similarity. It is a non-parametric algorithm, it learns from the dataset while it
performs actions on it and not immediately. KNN is mainly used for differentiating the data
into categories and for the identification of the class and category of a dataset.
2
ALGORITHM
Bayes Algorithm:
Naïve Bayes algorithm is a classifier learning algorithm. It's supported by the Bayes theorem
and used for finding the classification of datasets. Bayes theorem is also conjointly referred
to as Bayes Rule or Bayes law. It's used to calculate the chance of a specific dataset.
The formula for Bayes theorem is given as:
P(A|B) = P(B|A)P(A)/P(B)
Naïve Bayes formula is especially employed in text classification that features a high-
dimensional dataset. It's a probabilistic classifier, meaning it's used to predict on the premise
of the probability of an object. It's employed in Text classification like Spam filtering and
Sentiment analysis.
2
IMPLEMENTATION
2
I
REFERENCES
4
[1] Akrati Saxena, Harita Reddy, Pratishtha Saxena, "Introduction to Sentiment Analysis Covering Basics,
Tools, Evaluation Metrics, Challenges, and Applications", Principles of Social Networking, vol.246, pp.249,
2022.
[2] L. Tan, J. Na, Y. Theng, K. Chang, “Sentence-level Sentiment polarity classification using a
linguistic approach”, Digital Libraries: For Cultural Heritage, Knowledge Dissemination, and Future
Creation (2011) 77-87.
[3] Pratama BY, Sarno R., “Personality classification based on Twitter text using Naive Bayes, KNN and
SVM”. Proceedings of 2015 International Conference on Data and Software Engineering,ICODSE 2015;
2016. pp. 170–174. https://doi.org/10.1109/ICODSE.2015.7436992.
[4] R. Feldman, “Techniques and applications for
sentiment analysis”, Commun ACM, 56 (2013), pp. 82-
89.
[5] B. Liu, “Sentiment analysis and opinion
mining”, Synth Lect Human Lang Technol (2012)
[6] Agarwal, B. Xie, I. Vovsha, O. Rambow, R.
Passonneau, “Sentiment Analysis of Twitter Data", In
Proceedings of the ACL 2011Workshop on Languages in
Social Media,2011 , pp. 30-38.
2
I
CONCLUSION
4
In this study, we attempted and classified the data according to the
sentiments of the Twitter posts with the help of two algorithms- Naïve
Bayes and K-NN algorithm. The result after performance gives that
the K-NN algorithm has a greater accuracy percentage which is
85.667% while Naïve Bayes gives an accuracy precision of 80% hence
we can conclude that K-NN gives more precise and accurate results
and it should be used for precise prediction of the sentiments of the
users.

More Related Content

PDF
Paper-SentimentAnalysisofTweetshhhjjjjjjjj
PPTX
Twitter sentiment classifications 1
PDF
A Survey on Sentiment Analysis and Opinion Mining
PDF
A Survey on Sentiment Analysis and Opinion Mining
PDF
Sentiment Analysis and Classification of Tweets using Data Mining
PDF
IRJET - Sentiment Analysis for Marketing and Product Review using a Hybrid Ap...
PDF
Neural Network Based Context Sensitive Sentiment Analysis
PDF
Sentiment analysis with machine learning and deep learning A survey of techni...
Paper-SentimentAnalysisofTweetshhhjjjjjjjj
Twitter sentiment classifications 1
A Survey on Sentiment Analysis and Opinion Mining
A Survey on Sentiment Analysis and Opinion Mining
Sentiment Analysis and Classification of Tweets using Data Mining
IRJET - Sentiment Analysis for Marketing and Product Review using a Hybrid Ap...
Neural Network Based Context Sensitive Sentiment Analysis
Sentiment analysis with machine learning and deep learning A survey of techni...

Similar to Sentiment Analysis.pptx (20)

PDF
IRJET- An Extensive Study of Sentiment Analysis Techniques and its Progressio...
PDF
IRJET- A Review on: Sentiment Polarity Analysis on Twitter Data from Diff...
PDF
Sentiment Analysis on Twitter Data
PDF
Hypothesis on Different Data Mining Algorithms
PPTX
Cyber Bullying Detection using SVM and LSTM
PDF
A scalable, lexicon based technique for sentiment analysis
PDF
IRJET- Analysis of Brand Value Prediction based on Social Media Data
PPTX
Screening of Mental Health in Adolescence.pptx
PPTX
Detecting Threat messages using deep learning.pptx
PDF
PDF
Nt1310 Unit 1 Literature Review
DOCX
Abstract
PDF
IRJET - Cyberbulling Detection Model
PPTX
ashu ppt final.pptx
PDF
FEATURE SELECTION AND CLASSIFICATION APPROACH FOR SENTIMENT ANALYSIS
PDF
APPROXIMATE ANALYTICAL SOLUTION OF NON-LINEAR BOUSSINESQ EQUATION FOR THE UNS...
PDF
Methods for Sentiment Analysis: A Literature Study
PDF
76201960
PDF
Combining Lexicon based and Machine Learning based Methods for Twitter Sentim...
PDF
A study of cyberbullying detection using Deep Learning and Machine Learning T...
IRJET- An Extensive Study of Sentiment Analysis Techniques and its Progressio...
IRJET- A Review on: Sentiment Polarity Analysis on Twitter Data from Diff...
Sentiment Analysis on Twitter Data
Hypothesis on Different Data Mining Algorithms
Cyber Bullying Detection using SVM and LSTM
A scalable, lexicon based technique for sentiment analysis
IRJET- Analysis of Brand Value Prediction based on Social Media Data
Screening of Mental Health in Adolescence.pptx
Detecting Threat messages using deep learning.pptx
Nt1310 Unit 1 Literature Review
Abstract
IRJET - Cyberbulling Detection Model
ashu ppt final.pptx
FEATURE SELECTION AND CLASSIFICATION APPROACH FOR SENTIMENT ANALYSIS
APPROXIMATE ANALYTICAL SOLUTION OF NON-LINEAR BOUSSINESQ EQUATION FOR THE UNS...
Methods for Sentiment Analysis: A Literature Study
76201960
Combining Lexicon based and Machine Learning based Methods for Twitter Sentim...
A study of cyberbullying detection using Deep Learning and Machine Learning T...
Ad

Recently uploaded (20)

PDF
[jvmmeetup] next-gen integration with apache camel and quarkus.pdf
PDF
MACCAFERRY GUIA GAVIONES TERRAPLENES EN ESPAÑOL
PDF
Artificial Intelligence_ Basics .Artificial Intelligence_ Basics .
DOCX
An investigation of the use of recycled crumb rubber as a partial replacement...
PPTX
Real Estate Management PART 1.pptxFFFFFFFFFFFFF
PPTX
Module1.pptxrjkeieuekwkwoowkemehehehrjrjrj
PPTX
WN UNIT-II CH4_MKaruna_BapatlaEngineeringCollege.pptx
PDF
electrical machines course file-anna university
PPTX
DATA STRCUTURE LABORATORY -BCSL305(PRG1)
PDF
Engineering Solutions for Ethical Dilemmas in Healthcare (www.kiu.ac.ug)
PDF
Lesson 3 .pdf
PDF
IAE-V2500 Engine Airbus Family A319/320
PPT
Programmable Logic Controller PLC and Industrial Automation
PPT
UNIT-I Machine Learning Essentials for 2nd years
PDF
Cryptography and Network Security-Module-I.pdf
PDF
Using Technology to Foster Innovative Teaching Practices (www.kiu.ac.ug)
PPTX
ARCHITECTURE AND PROGRAMMING OF EMBEDDED SYSTEMS
PDF
LS-6-Digital-Literacy (1) K12 CURRICULUM .pdf
PDF
MLpara ingenieira CIVIL, meca Y AMBIENTAL
PPTX
INTERNET OF THINGS - EMBEDDED SYSTEMS AND INTERNET OF THINGS
[jvmmeetup] next-gen integration with apache camel and quarkus.pdf
MACCAFERRY GUIA GAVIONES TERRAPLENES EN ESPAÑOL
Artificial Intelligence_ Basics .Artificial Intelligence_ Basics .
An investigation of the use of recycled crumb rubber as a partial replacement...
Real Estate Management PART 1.pptxFFFFFFFFFFFFF
Module1.pptxrjkeieuekwkwoowkemehehehrjrjrj
WN UNIT-II CH4_MKaruna_BapatlaEngineeringCollege.pptx
electrical machines course file-anna university
DATA STRCUTURE LABORATORY -BCSL305(PRG1)
Engineering Solutions for Ethical Dilemmas in Healthcare (www.kiu.ac.ug)
Lesson 3 .pdf
IAE-V2500 Engine Airbus Family A319/320
Programmable Logic Controller PLC and Industrial Automation
UNIT-I Machine Learning Essentials for 2nd years
Cryptography and Network Security-Module-I.pdf
Using Technology to Foster Innovative Teaching Practices (www.kiu.ac.ug)
ARCHITECTURE AND PROGRAMMING OF EMBEDDED SYSTEMS
LS-6-Digital-Literacy (1) K12 CURRICULUM .pdf
MLpara ingenieira CIVIL, meca Y AMBIENTAL
INTERNET OF THINGS - EMBEDDED SYSTEMS AND INTERNET OF THINGS
Ad

Sentiment Analysis.pptx

  • 2. Table of Contents 2 Problem Definition Introduction Motivation Literature Survey Implementation I II III IV V VI Algorithm taken to implement VII Conclusion VIII References
  • 3. 2 PROBLEM DEFINITION Sentiment Analysis and Classification of Tweets Using Classification Algorithms like Naive Bayes and K-NN Algorithm.
  • 4. 2 In recent times, people have started using social media sites more often and it has become an important aspect to analyze and find what they think about the content on social media and what reactions they give. Data classification is the process of categorizing analyzed data to make it more effective and productive. The classification's goal is to accurately predict the target class for each and every case in the data. A classifier is basically an algorithm that is specifically designed to implement classification. The data that is collected from the users should be analysed and it should be properly processed and used for the identification of the sentiments of the users. . The data set that we get from the users is very large and not all of it is useful, proper selection and extraction of data needs to be done in order to separate out the useful data. I INTRODUCTION 3
  • 5. 2 So, text mining is the process that is used for extraction of the useful data. It helps in getting the exact information and meaningful data from the text. For applying the data mining algorithms some processes need to be carried out, such as natural language processing or information retrieval methods, or some pre-processing of text. .We will be using two classifiers for the extraction of sentiments and thoughts of people based on what they share on Twitter and how they respond to other people’s tweets and classify their tweets into categories. By comparing the results of all two classifiers we will be able to find out which classifier gives the most accurate result in terms of precision and accuracy I INTRODUCTION 4
  • 6. 2 MOTIVATION For new technologies in this decade, we need a solution that can create the perfect model to solve that particular problem. The sentiments of the people are difficult to understand when it comes to social media and hence it needs to be analyzed and processed properly and accurately.
  • 7. 2 No. Techniques Summary limitations 1 Naïve Bayes algorithm Naïve Bayes algorithm is a classifier learning algorithm. It's supported by the Bayes theorem and used for finding classification of datasets. This algorithm faces the ‘zero- frequency problem’ where it assigns zero probability to a variable whose category in the test data set wasn’t available in the training dataset 2 KNN-precision K-NN algorithm is K-Nearest Neighbor and it checks for the similarity between the new data and available data and puts our new case in a category that best fits. Accuracy depends on the type of the data. With large data, the prediction stage might become slow. LITERATURE SURVEY
  • 8. 2 ALGORITHM The two algorithms we have used to classify the tweets are: • KNN Algorithm • Naive Bayes Algorithm KNN Algorithm: K-NN algorithm is K-Nearest Neighbour and it checks for the similarity between the new data and available data and puts our new case in a category that best fits. It mainly works on the principle of similarity. It is a non-parametric algorithm, it learns from the dataset while it performs actions on it and not immediately. KNN is mainly used for differentiating the data into categories and for the identification of the class and category of a dataset.
  • 9. 2 ALGORITHM Bayes Algorithm: Naïve Bayes algorithm is a classifier learning algorithm. It's supported by the Bayes theorem and used for finding the classification of datasets. Bayes theorem is also conjointly referred to as Bayes Rule or Bayes law. It's used to calculate the chance of a specific dataset. The formula for Bayes theorem is given as: P(A|B) = P(B|A)P(A)/P(B) Naïve Bayes formula is especially employed in text classification that features a high- dimensional dataset. It's a probabilistic classifier, meaning it's used to predict on the premise of the probability of an object. It's employed in Text classification like Spam filtering and Sentiment analysis.
  • 11. 2 I REFERENCES 4 [1] Akrati Saxena, Harita Reddy, Pratishtha Saxena, "Introduction to Sentiment Analysis Covering Basics, Tools, Evaluation Metrics, Challenges, and Applications", Principles of Social Networking, vol.246, pp.249, 2022. [2] L. Tan, J. Na, Y. Theng, K. Chang, “Sentence-level Sentiment polarity classification using a linguistic approach”, Digital Libraries: For Cultural Heritage, Knowledge Dissemination, and Future Creation (2011) 77-87. [3] Pratama BY, Sarno R., “Personality classification based on Twitter text using Naive Bayes, KNN and SVM”. Proceedings of 2015 International Conference on Data and Software Engineering,ICODSE 2015; 2016. pp. 170–174. https://doi.org/10.1109/ICODSE.2015.7436992. [4] R. Feldman, “Techniques and applications for sentiment analysis”, Commun ACM, 56 (2013), pp. 82- 89. [5] B. Liu, “Sentiment analysis and opinion mining”, Synth Lect Human Lang Technol (2012) [6] Agarwal, B. Xie, I. Vovsha, O. Rambow, R. Passonneau, “Sentiment Analysis of Twitter Data", In Proceedings of the ACL 2011Workshop on Languages in Social Media,2011 , pp. 30-38.
  • 12. 2 I CONCLUSION 4 In this study, we attempted and classified the data according to the sentiments of the Twitter posts with the help of two algorithms- Naïve Bayes and K-NN algorithm. The result after performance gives that the K-NN algorithm has a greater accuracy percentage which is 85.667% while Naïve Bayes gives an accuracy precision of 80% hence we can conclude that K-NN gives more precise and accurate results and it should be used for precise prediction of the sentiments of the users.