Sentiment Analysis of Political Parties on social media: A Machine Learning and Lexicon-Based Approach
Swapnil P. Goje and
Rupali H. Patil
International Journal of Scientific Research in Computer Science, Engineering and Information Technology, 2024, vol. 10, issue 5, 233-246
Abstract:
Social media platforms like Facebook, Twitter, Instagram, and YouTube have become central to communication and entertainment, with users sharing opinions on various topics. These opinions, often categorized as positive, negative, or neutral sentiments, provide valuable data for sentiment analysis. Our research analyzed political YouTube comments related to India’s Bhartiya Janata Party (BJP) and Indian National Congress (INC) using a combination of the AFINN lexicon and machine learning techniques. We applied feature representation methods such as Bag of Words (BoW) and Term Frequency-Inverse Document Frequency (TF-IDF), alongside five machine learning algorithms: Multinomial Naïve Bayes, Logistic Regression, Random Forest, Support Vector Machine (SVM), and K-nearest neighbor (K-NN). We aimed to determine the most efficient sentiment analysis approach by comparing the performance of these models using standard evaluation metrics. For the BJP dataset, Logistic Regression performed best with BoW, while SVM was most effective with TF-IDF. Similarly, for the INC dataset, Random Forest excelled with BoW, and SVM outperformed others with TF-IDF. The AFINN lexicon showed poor performance across both datasets, and K-NN consistently achieved lower accuracy. Our findings suggest that SVM and Random Forest are more suitable for political sentiment analysis.
Keywords: Term Frequency-Inverse Document Frequency; Multinomial Naïve Bayes; Logistic Regression; Random Forest; Support Vector Machine; K-Nearest Neighbor (search for similar items in EconPapers)
Date: 2024
Note: Article URL: https://ijsrcseit.com/home/article/view/CSEIT24105103
References: Add references at CitEc
Citations:
Downloads: (external link)
https://ijsrcseit.com/home/article/view/CSEIT24105103 Article URL (text/html)
https://ijsrcseit.com/home/article/download/CSEIT24105103/CSEIT24105103 Full text (application/pdf)
Related works:
This item may be available elsewhere in EconPapers: Search for items with the same title.
Export reference: BibTeX
RIS (EndNote, ProCite, RefMan)
HTML/Text
Persistent link: https://EconPapers.repec.org/RePEc:jbh:ijsrcs:v10:y2024:i5:id:308
DOI: 10.32628/CSEIT24105103
Access Statistics for this article
More articles in International Journal of Scientific Research in Computer Science, Engineering and Information Technology from International Journal of Scientific Research in Computer Science, Engineering and Information Technology
Bibliographic data for series maintained by Pankaj Sharma (USA) ().