Analisis Sentimen Calon Gubernur Jawa Tengah 2024 Menggunakan Metode Naïve Bayes - Nuh Hanan, Martin; Muhammad Jumasa, Hamid; Yunia Pasa, Ike (JURNAL FASILKOM, 2025)
Social media platform X (formerly Twitter) has become a public space where people can freely express their opinions, including in the context of regional elections. These opinions can be processed into useful information for decision-makers, especially in political contexts. This study aims to analyze public sentiment toward the candidates for Governor of Central Java for the 2024–2029 period using the Naïve Bayes method. The data was collected through a crawling process on X using Tweet-Harvest and relevant keywords. The raw data then underwent preprocessing, including cleaning, case folding, normalization, stopword removal, tokenization, and stemming. Sentiment labeling was performed automatically using the TextBlob library, which classified tweets into positive, negative, or neutral categories. Naïve Bayes was chosen for its effectiveness and efficiency in text classification tasks. The results showed model accuracy of 90.28% for Andika Perkasa and 84.51% for Ahmad Luthfi, using a 90:10 training-to-testing data ratio. Out of 452 total tweets, Andika Perkasa received 350 positive sentiments, slightly more than Ahmad Luthfi, who received 336. These findings indicate that public perception toward both candidates is generally positive, with a slight edge for Andika Perkasa.