Jurnal Lebesgue (Dec 2024)

PENERAPAN METODE NAÏVE BAYES CLASSIFIER DALAM MENGANALISIS SENTIMEN PADA MEDIA SOSIAL X TERHADAP PILPRES 2024 DI INDONESIA

  • Ridha Fauza Majbur,
  • Ferra Yanuar,
  • Dodi Devianto

DOI
https://doi.org/10.46306/lb.v5i3.794
Journal volume & issue
Vol. 5, no. 3
pp. 2012 – 2025

Abstract

Read online

The purpose of this research is to analyze sentiment on social media X regarding the 2024 Presidential Election by testing data using k-fold cross validation. The data used in this study are tweets about the 2024 Presidential Election on social media X, obtained through data crawling techniques. Sentiment analysis is the process of identifying and classifying opinions, which are in text form into positive or negative sentiments. Classification methods are used to group these sentiments. One of the classification methods used in this study is the Naive Bayes Classifier (NBC). The accuracy of this NBC method is measured using k-fold cross-validation, with k = 10. The value of k = 10 was chosen for this study because it is considered to provide more stable and robust accuracy results. Based on the measurements conducted, it was found that the highest accuracy value occurred in the 10th fold, which was 92.06%. The average accuracy across all folds for the NBC method was 82.33%. This indicates that the Naive Bayes Classifier (NBC) method can classify public sentiment towards the 2024 Presidential Election with a relatively high level of accuracy.

Keywords