A Comprehensive Analysis of Sentiment Analysis Approaches Applications and Classifier Comparisons
A Comprehensive Analysis of Sentiment Analysis Approaches Applications and Classifier Comparisons
Comparisons
Abstract In the present era, an enormous amount of textual This research serves as a valuable resource for scholars and
content is being generated across various platforms, including beginners, consolidating knowledge about sentiment analysis in
messaging apps like Telegram and WhatsApp, social media sites a single paper.
like Instagram and Facebook, news websites, and online search
engines like Google. These sources generate an endless stream of The survey's main contributions include a thorough
text data. Consequently, natural language processing (NLP) has examination of sentiment analysis processes, identification of
become an indispensable tool for comprehending and analyzing well-known technologies, analysis of methodologies suitable
this textual content. for specific applications, classification and summary of
frequently used approaches, and a discussion of the benefits and
This paper specifically focuses on sentiment analysis related to challenges of sentiment analysis. The paper also provides
NLP. Sentiment analysis involves the contextual analysis of text to method comparisons, highlighting their advantages and
identify and extract subjective information. Sentiment analysis disadvantages, to guide the selection of appropriate methods for
can be used to extract crucial insights from user feedback, helping sentiment analysis tasks. The paper's structure includes sections
organizations understand the social sentiment surrounding their on the levels of sentiment analysis, data collection and feature
brand, product, or service. This paper explores various extraction, general methodology, sentiment analysis
approaches and classification models used in sentiment analysis, applications, challenges, and concluding remarks.
discussing their effectiveness and applicability.
Furthermore, this paper delves into the widely used machine behind customer questions, automate tasks, and gain valuable
learning techniques used for sentiment analysis and explores insights.
the diverse classifiers employed within those approaches.
Intent classification enables organizations to enhance
customer-friendliness, particularly in customer support and
sales. It facilitates faster response times to leads and the
III. RELATED WORKS handling of high volumes of inquiries, improving overall
Over the past few years, there has been a substantial customer satisfaction.
increase in the adoption of machine learning, deep learning, and B. Aspect-based analysis
transformer-based algorithms for sentiment analysis.
Aspect-based analysis is type of sentiment analysis. It
Sentiment analysis using machine learning has been focuses on specific aspects of a service or product. It plays a
explored by several researchers. crucial role in automatically categorizing and analyzing
Tirath Prasad Sahu [1] used a method that looked at the customer data, enabling organizations to gain valuable insights
words in a document to determine its polarity. Different in real-time. By employing aspect-based sentiment analysis,
classification algorithms like KNN, DT (Decision Tree), and businesses can identify and address the specific areas that
NB (Naïve Bayes) were used on the IMDB dataset to calculate customers are complaining about, allowing for prompt issue
a sentiment score. resolution. This analysis is particularly helpful for identifying
and addressing issues such as software bugs in new
Arafat Habib Quraishi [2] used ML and DL algorithms such applications.
as SVM, GRU, and LSTM on the IMDB dataset. They
determined that deep learning algorithms outperformed C. Fine-grained sentiment
traditional machine learning algorithms for binary Fine-grained sentiment analysis is a simple and common
classification. way to understand customer sentiment. It involves categorizing
customer feedback into negative, positive and neutral classes.
T.Nikhil.Prakash [3] used lexicon-based, machine learning, Rating is another way to scale customer feedback, i.e., 1 t 5.
and hybrid algorithms. They examined sentiment analysis at Most e-commerce sites use this technique to understand
different levels, including sentence, document, and topical customer sentiment.
level.
Study by Zulfadzli Drus [4] found that the opinion-lexicon
method was a popular approach for sentiment analysis in social V. SENTIMENT ANALYSIS APPROACHES
media text.
A. Machine learning
Saad Abdul Rauf [5] employed a transformer-based model
Machine learning approaches in sentiment analysis rely on
called BERT for sentiment analysis on the IMDB dataset.
algorithms and data-driven processes rather than manually
BERT showed impressive performance compared to previous
crafted rules. In this approach, sentiment analysis is type of
ML and DL models.
classification problem. Classifier takes text data and assigns to
Qizhe Xie [6] introduced UDA (Unsupervised Data a class such as negative, positive, or neutral [12].
Augmentation) in combination with BERT for sentiment
analysis. This approach surpassed previous DL models by a
significant margin.
Authorized licensed use limited to: BMS College of Engineering. Downloaded on October 18,2024 at 09:59:39 UTC from IEEE Xplore. Restrictions apply.
2023 5th International Conference on Advances in Computing, Communication Control and Networking (ICAC3N)
As shown in Figure 2, the feature extractor converts unseen with additional rules to handle sentences containing dependent
text inputs into feature vectors during the prediction process. clauses, negations, and sarcasm [8-11]. NLP techniques, such
The model then generates prediction tags for these vectors. as stemming, tokenization, and part-of-speech tagging, are used
alongside lexicons.
Machine learning approaches in sentiment analysis
eliminate the need for manually designing rules, allowing the Systems based on rule-based approaches are relatively
model to learn patterns and make predictions based on the straightforward since they do not consider the sequential
provided training data. This approach enables flexibility and relationship between words. This allows for the utilization of
scalability, as models can be trained on various datasets and efficient processing methods and the incorporation of new rules
easily adapted to handle different sentiment analysis tasks. to accommodate evolving expressions and vocabularies. Rule-
based systems can be complex and require regular maintenance.
B. Lexicon based approach Adding new rules can impact previously obtained results and
Lexicon-based approaches determine the sentiment may require additional fine-tuning. This can be costly and time-
orientation of a text or a set of sentences by using the semantic consuming.
orientation of lexicons. Lexicons can be manually created or
automatically generated [13]. D. Advantages and Limitations of All the Approaches
The following table-1 summarizes the advantages and
The sentiment categorization task using the lexicon-based
approach is executed as follows, as shown in Figure 3. The limitations of machine learning, lexicon-based and rule-based
sentiment weights of the training text data and the categorized approaches to sentiment analysis.
text are first calculated. Textual data is stored in 1D emotion
field. Then, the training text data, the average sentiment weights TABLE I. ADVANTAGES AND LIMITATIONS OF ALL THE APPROACHES
of per category are calculated. The categorized text is then Approach Advantages Limitations
assigned to the category with the closest average sentiment Requires more
More accurate than
weight in 1D emotion field [14]. rule-based approaches.
training data.
Classifiers trained on
Lexicon-based approach relies on the sentiment orientation No need for a
Machine textual data from a
dictionary.
assigned to words in the lexicon to determine the overall learning[15]
Demonstrates high
single field often do
sentiment of a text. This method can be effective when there is not work well with
precision in
a comprehensive and accurate lexicon available. However, it data from different
classification.
fields.
may face challenges in dealing with context-dependent Not as accurate as
sentiments and nuances in language. Fast and efficient. machine learning
Named information approaches.
Lexicon
and the learning Requires extensive
based[15]
method are not semantic resources
required. that are not always
readily available.
Not as accurate as
machine learning
Easy to implement.
approaches.
No training data
Rule based Lower recall.
required.
Challenging and time-
High precision
consuming to
enumerate all the rules
Authorized licensed use limited to: BMS College of Engineering. Downloaded on October 18,2024 at 09:59:39 UTC from IEEE Xplore. Restrictions apply.
2023 5th International Conference on Advances in Computing, Communication Control and Networking (ICAC3N)
P(A | B) = P(A) * P(B | A) / P(A) (1) By determining the hyperplane, the test data is classified
based on the weights and considering positive or negative
0. classes[17].
Conditional probability (A | B) represents the probability of
observing event A given that event B is true. 4) K-Nearest Neighbor (k-NN): This is a straightforward
P(A) and P(B) are the probabilities of observing events A and supervised machine learning technique used for both
and B independently, without considering each other. classification and regression problems[16].
P(B | A) denotes the probability of observing event B given
that event A is true. KNN classifies new objects based on the value of k, which
should be less than the size of the training data. Target
2) Decision Tree (DT): Decision Tree is another category of the object is determined by considering the k
supervised learning algorithm used for efficiently handling non- nearest neighbors in the training data [17].
linear datasets. It is particularly effective in constructing
classification models based on available data and is commonly The distance between the test data (a) and the training data
employed in conjunction with logical techniques [19]. (b) is calculated using the Euclidean Distance formula, as
shown in equation (5):
A Decision Tree is a flowchart-like structure that resembles
a tree. Each leaf node or terminal node represents a class - bk)² (5)
label, while the root node is the node located at the top of Here, D represents the scalar distance between the
the decision tree [19]. respective vectors, a represents the test data, and b
represents the train data.
The entropy of a decision tree is calculated using equation
(2): After calculating the Euclidean Distance, the results are
sorted and the classes are determined based on the K value,
( )*log( ( )) (2) considering the data quantity in a specific order.
B. Deep Learning Based Classifiers
Here, ( ) represents the probability of class C(i) in a node.
E(D), also known as the entropy of D, measures the level of Deep learning models use neural networks. These models
disorder in the considered samples. are inspired by working way of human brains. These models
learn from the provided data by adjusting weight parameters
and undergoing continuous training over multiple epochs,
3) Support Vector Machine (SVM): Supervised machine simulating the learning process of the human brain [18]. In this
learning algorithms, such as Support Vector Machines (SVM), analysis, we consider deep learning models such as LSTM and
analyze data and identify patterns for classification. SVM is GRU, which are known for their effectiveness with sequence
capable of identifying separate hyperplanes to maximize the and textual data.
margin between different classes [18].
1) Gated Recurrent Unit (GRU): It is a simplified variant
The methodology for classifying using the SVM algorithm of the Long Short-Term Memory (LSTM) model [5]. Despite
having fewer parameters compared to LSTM, GRU is capable
begins with transforming text data into weights. These
of effectively capturing long-term dependencies in sequences.
weights are combined to calculate TF-IDF values by
As a result, GRU exhibits comparable performance to LSTM
multiplying them together [17]. To determine positive or
while being computationally efficient [12].
negative sentences, the hyperplane is calculated using
equations (3) and (4) as follows:
GRU incorporates two gates known as the update gate and
the reset gate, which regulate the flow of information within
f( (x)) = sign(w. (x) + b) (3)
Authorized licensed use limited to: BMS College of Engineering. Downloaded on October 18,2024 at 09:59:39 UTC from IEEE Xplore. Restrictions apply.
2023 5th International Conference on Advances in Computing, Communication Control and Networking (ICAC3N)
C. Transformer-Based Models
Transformer models are a type of deep learning model that
uses the attention mechanism and a sequence-to-sequence
architecture. The attention mechanism allows the model to
focus on relevant parts of input sequences, making decisions
based on their importance at each step [19-21]. An example of
this model is BERT (Bidirectional Encoder Representations
The operation of LSTM and GRU cells is depicted in Figure from Transformers), which is specifically designed and fine-
4, showcasing the functioning of these units within a neural tuned for natural language processing (NLP) tasks. BERT has
network architecture [5]. gained significant attention and popularity in the NLP research
community.
2) Long Short-Term Memory Model (LSTM): It is a type 1) BERT: BERT is a bidirectional NLP model introduced
of Recurrent Neural Network (RNN) unit commonly used for by Google AI in 2018. It is based on the Transformer
tasks involving time series data, such as classification and architecture and can be fine-tuned for a variety of NLP tasks.
prediction. LSTM models are designed to address challenges
related to exploding and vanishing gradients that are often
encountered in traditional RNNs. One significant issue in RNNs
is the difficulty in capturing long-term dependencies, and
LSTM models are specifically designed to overcome this
problem [5].
Authorized licensed use limited to: BMS College of Engineering. Downloaded on October 18,2024 at 09:59:39 UTC from IEEE Xplore. Restrictions apply.
2023 5th International Conference on Advances in Computing, Communication Control and Networking (ICAC3N)
TABLE II. COMPARISON OF THE CLASSIFICATION MODELS on the market and provides valuable insights into how products
Classification Model Accuracy
are perceived from the customer's point of view. It can also be
used to analyze competitors and their marketing efforts. Here
Naive Bayes [1] 54.77% are some ways sentiment analysis can be utilized:
Decision Tree [1] 87.53% - View relevant information across different
Conventional
Machine learning Support Vector Machine (SVM) platforms
88.3%
[2]
- Customer-generated content
k-Nearest Neighbor (k-NN) [1] 88.86%
- News reports
GRU [2] 89.0%
Deep Learning
based - Expert content
LSTM [2] 88.5%
- Competitor's content
Transformer based BERT [5] 89.5%
- Obtain insights on different scales
- General public sentiment
- Specific product features
VII. APPLICATIONS OF SENTIMENT ANALYSIS
- Generate real-time results
A. Product Analytics
- Keep track of all business intelligence
Sentiment analysis plays a crucial role in product analysis,
which is closely related to reputation management and brand By leveraging sentiment analysis, companies can better
observation. It involves analyzing explicit remarks and understand customer needs and preferences, improve their
comments about products to gain valuable insights. value proposition, and achieve optimal outcomes.
These insights are particularly important during critical 1) Example-Apple: Apple serves as a prime example of
stages of product development, where real customer feedback how sentiment analysis can be applied for competitor analysis
is essential for refining and enhancing the product. Sentiment and market research. Apple carefully showcases its products to
analysis is commonly used to collect and categorize feedback align with various customer concerns. For example, addressing
for improvements [4]. concerns about design, privacy and battery life.
Sentiment analysis algorithms can reveal the nature of
customer feedback and provide information on when the Through sentiment analysis, Apple effectively identifies
feedback was received. and addresses customer pain points, gaining a competitive
1) Example-Google: A prime example of how sentiment edge in the market. It highlights the importance of
analysis is used for product improvement can be seen in understanding customer sentiment and tailoring product
Google's approach, specifically with their web browser messaging to meet their needs.
Chrome. C. Voice of the Customer Analysis
The Chrome development team consistently monitors user One of the crucial elements of an effective business
reviews, focusing not only on the feedback itself but also on operation is precise target audience segmentation and
various aspects, such as: subsequent value proposition definition. It is essential to know
who you are targeting and with what offering.
- Customer sentiment
On the other hand, staying relevant and keeping your
- Specific features of the product, including product popular requires staying connected to your customers
flexibility, extensions, security, and user interface and understanding their needs. At the core of these activities
- Emotional needs and overall perceptions of the lies the understanding of the "Voice of the customer."
product, including specific details
However, capturing and studying the voice of the customer
is not a straightforward task. It is spread across various
By leveraging sentiment analysis, Google gains valuable
platforms and presented in different, sometimes conflicting,
insights into user feedback, allowing them to address issues, forms. This complexity needs to be carefully addressed.
refine their product, and meet customer expectations more
effectively. This highlights the importance of utilizing 1) Example-TripAdvisor: An excellent example of
sentiment analysis for continuous product improvement. effective Voice of the Customer (VOC) analysis is
demonstrated by TripAdvisor. The organization employs
B. Market Research and Competitor Analysis perspective-based sentiment analysis to extract valuable
Sentiment analysis is widely used in market research to gain insights from the vast amount of data it generates. This
insights into customer perceptions and evaluate the competitive approach allows them to identify the specific areas of focus in
landscape. While sentiment analysis may not be the primary customer feedback and actual service delivery.
method for market research, it offers an additional perspective
Authorized licensed use limited to: BMS College of Engineering. Downloaded on October 18,2024 at 09:59:39 UTC from IEEE Xplore. Restrictions apply.
2023 5th International Conference on Advances in Computing, Communication Control and Networking (ICAC3N)
Authorized licensed use limited to: BMS College of Engineering. Downloaded on October 18,2024 at 09:59:39 UTC from IEEE Xplore. Restrictions apply.
2023 5th International Conference on Advances in Computing, Communication Control and Networking (ICAC3N)
[6] Qizhe Xie, "Unsupervised Data Augmentation for Polarity Shifting Devices. The 13th Workshop on Asian
Sentiment Analysis with BERT," arXiv preprint Language Resources, Miyazaki, Japan, May 2018, pp. 21
arXiv:1901.11196, 2019. 28. Kiyoaki Shirai
[7] Bo Pang, Lillian Lee, and Shivakumar Vaithyanathan. [14] R.K. Dash, T.N. Nguyen, K. Cengiz, A. Sharma, Fine-
2002. Thumbs up? sentiment classification using machine tuned support vector regression model for stock
learning techniques. In Proceedings of the ACL-02 predictions, in: Neural Computing and Applications, 2021,
conference on Empirical methods in natural language pp. 1 15.
processing - Volume 10 (EMNLP '02). Association for [15] M.D. Devika, C. Sunitha, A.mal Ganesh, Sentiment
Computational Linguistics, USA, 79 86. Analysis: A Comparative Study on Different Approaches,
https://doi.org/10.3115/1118693.1118704 Procedia Comput. Sci. 87 (2016) 44 49 VolumePages
[8] A. Vaswani, N. Shazeer, N. Parmar, J. Uszkoreit, L. Jones, [16] A. Bayhaqy, S. Sfenrianto, K. Nainggolan, E.R. Kaburuan,
A.N. Gomez, L. Kaiser, & I. Polosukhin. (2017). Attention Sentiment Analysis about E-Commerce from Tweets
Is All You Need. Using Decision Tree, K-Nearest Neighbor, and Naïve
[9] G. Ranjan, T.N. Nguyen, H. Mekky, Z.L. Zhang, On Bayes, in: 2018 International Conference on Orange
virtual id assignment in networks for high resilience Technologies (ICOT), 2018, pp. 1 6.
routing: a theoretical framework, in: GLOBECOM 2020- [17] S.S. Istia, H.D. Purnomo, Sentiment Analysis of Law
2020 IEEE Global Communications Conference, IEEE, Enforcement Performance Using Support Vector Machine
2020, pp. 1 6. and K-Nearest Neighbor, in: 2018 3rd International
[10] B.D. Parameshachari, H.T. Panduranga, S. liberata Ullo, Conference on Information Technology, Information
Analysis and computation of encryption technique to System and Electrical Engineering (ICITISEE), 2018, pp.
enhance security of medical images, IOP Conference 84 89
Series: Materials Science and Engineering, 925, IOP [18] Rawal G., Rawal R., Shah H., Patel K. (2020) A
Publishing, 2020. Comparative Study Between Artificial Neural Networks
[11] T, N. & Aloysius, A.. (2020). APPLICATIONS, and Conventional Classifiers for Predicting Diagnosis of
APPROACHES, AND CHALLENGES IN SENTIMENT Breast Cancer. In: Kumar A., Paprzycki M., Gunjan V.
ANALYSIS (AACSA). (eds) ICDSMLA 2019. Lecture Notes in Electrical
[12] Engineering, vol 601. Springer, Singapore
Tiz.iana Guzzo, Approaches, Tools and Applications for [19] Ti.ng Lan, Hu.i Hu, Chu.nhua Jiang, Gu.obin Yang,
Sentiment Analysis Implementation, International Journal Zhen.gyu Zhao, A comparative study of decision tree,
of Computer Applications 125 (2015) 26 33. random forest, and convolutional neural network for
[13] Gw.anghoon Yoo, Jee.sun Nam, in: A Hybrid Approach to spread-F identification, Adv. Space Res. 65 (8) (2020)
Sentiment Analysis Enhanced by Sentiment Lexicons and 2052 2061 VolumeIssuePages.
Authorized licensed use limited to: BMS College of Engineering. Downloaded on October 18,2024 at 09:59:39 UTC from IEEE Xplore. Restrictions apply.