Comparison of Machine Learning Models for Classifying Consumer Sentiment of Coffee Shops on Social Media X

Authors

  • Agung Putra Pamungkas Universitas Gadjah Mada
  • Adam Mahendra Universitas Gadjah Mada
  • Ibnu Wahid Fakhrudin Aziz Universitas Gadjah Mada

DOI:

https://doi.org/10.23960/jtepl.v14i5.1905-1912
Abstract View: 189

Keywords:

Logistic regression, Naïve bayes, Sentiment analysis, Social media, Support vector machine

Abstract

With the intense competition in the coffee shop industry, understanding consumer opinions has become crucial for businesses. This study analyzes consumer sentiment toward the Janji Jiwa and Kopi Kenangan brands using tweet data from platform X. Sentiments were classified into positive, neutral, and negative categories using three algorithms: Logistic Regression (LR), Naïve Bayes (NB), and Support Vector Machine (SVM). The performance of these algorithms, in terms of accuracy and predictive capability, was evaluated using the TF-IDF method for text representation. The evaluation results show that LR achieved the highest accuracy at 79%, followed by SVM (78%) and NB (75%). Additionally, LR recorded consistent and balanced scores across the precision, recall, and F1-score metrics. These findings indicate that LR and SVM are more effective for multiclass sentiment classification in social media contexts

Downloads

Download data is not yet available.

Author Biographies

Agung Putra Pamungkas, Universitas Gadjah Mada

Department of Agroindustrial Technology, Faculty of Agricultural Technology

Adam Mahendra, Universitas Gadjah Mada

Department of Agroindustrial Technology, Faculty of Agricultural Technology

Ibnu Wahid Fakhrudin Aziz, Universitas Gadjah Mada

Department of Agroindustrial Technology, Faculty of Agricultural Technology

References

Alfajri, M.F., Adhiazni, V., & Aini, Q. (2019). Pemanfaatan social media analytics pada Instagram dalam peningkatan efektivitas pemasaran. Interaksi: Jurnal Ilmu Komunikasi, 8(1), 34–42. https://doi.org/10.14710/interaksi.8.1.34-42

Amalia, F.N., Ariadi, B.Y., & Widyastuti, D.E. (2022). Comparative analysis of brand equity of Janji Jiwa Coffee Shop with Kenangan Coffee Shop in Malang City. AGRIMOR, 7(2), 45-53. https://doi.org/10.32938/ag.v7i2.1589

Anugrah, D.P., & Suparwito, H. (2022). Analisis sentimen bantuan langsung tunai COVID-19 menggunakan algoritma support vector machine. Seminar Nasional Sanata Dharma Berbagi 2022. Accessed on September 19, 2025 from: https://e-conf.usd.ac.id/index.php/usdb/usdb2022/paper/view/1730

Budianto, A.G., Rusilawati, Suryo, A.T.E., Cahyono, G.R., Zulkarnain, A.F., & Martunus. (2024). Perbandingan performa algoritma support vector machine (SVM) dan logistic regression untuk analisis sentimen pengguna aplikasi retail di android. Jurnal Sains dan Informatika, 10(2). https://doi.org/10.34128/jsi.v10i2.911

Daqiqil, I. (2021). Machine Learning: Teori, Studi Kasus, dan Implementasi Menggunakan Python. Pekanbaru: UR Press. Diakses dari https://zenodo.org/records/5113507

Han, J.W., & Kamber, M. (2001). Data Mining: Concepts and Techniques. San Francisco: Morgan Kaufman Publisher. Diakses dari https://hanj.cs.illinois.edu/bk2/toc.pdf

Hasri, C.F., & Alita, D. (2022). Penerapan metode naive bayes classifier dan support vector machine pada analisis sentimen terhadap dampak virus corona di twitter. Jurnal Informatika dan Rekayasa Perangkat Lunak (JATIKA), 3(2), 145-160. Diakses dari https://jim.teknokrat.ac.id/index.php/informatika/article/view/2026

Henderi & Siddique, Q. (2024). Comparative analysis of sentiment classification techniques on flipkart product reviews: A study using logistic regression, SVC, random forest, and gradient boosting. Journal of Digital Market and Digital Currency, 1(1), 21-42. https://doi.org/10.47738/jdmdc.v1i1.4

Hidayah, N., Nur, A., Supira, W., Fauziah, E., Ratna, S., Fuzi, Y., Ramadita, N., Rifki, M., Haidar, M., Martin, S., & Huda, M. (2024). Analisis perbandingan customer experience dan harga pada coffee shop “Kopi Kenangan”, "Janji Jiwa" dan “Starbucks” di Cikarang. Journal of Management and Creative Business, 2(3), 255-267. https://doi.org/10.30640/jmcbus.v2i3.2871

Hosmer, D.W., Lemeshow, S., & Sturdivant, R.X. (2013). Applied Logistic Regression (Vol. 398). John Wiley & Sons. Diakses dari https://dl.icdst.org/pdfs/files4/7751d268eb7358d3ca5bd88968d9227a.pdf

Kamruzzaman, M. & Kim, G.L. (2023). Efficient sentiment analysis: a resource-aware evaluation of feature extraction techniques, ensembling, and deep learning models. Proceeding of the 11th International Workshop on Natural Language Processing for Social Media, 9-20. https://aclanthology.org/2023.socialnlp-1.2.pdf

Liu, B. (2012). Sentiment analysis and opinion mining. Morgan & Claypool Publishers. Diakses dari https://www.cs.uic.edu/~liub/FBS/SentimentAnalysis-and-OpinionMining.pdf

Mardikaningsih, R. (2021). Pencapaian kepuasan pelanggan pada jasa pengiriman barang melalui harga, ekuitas merek, dan kualitas pelayanan. Jurnal Baruna Horizon, 4(1), 64-73. https://doi.org/10.52310/jbhorizon.v4i1.58

Mahendra, A., Pamungkas, A.P., & Aziz, I.W.F. (2023). Analisis sentimen dari media sosial twitter terhadap Kopi Janji Jiwa dan Kopi Kenangan menggunakan Metode Machine Learning. [Undergraduated Thesis]. Universitas Gadjah Mada.

Manning, C.D., Raghavan, P., & Schütze, H. (2008). Introduction to Information Retrieval. Cambridge University Press. Diakses dari https://nlp.stanford.edu/IR-book/pdf/irbookonlinereading.pdf

Maulana, A.N., Pamungkas, A.P., & Falah, M.A.F. (2021). Sentimen Ulasan untuk Peningkatan Layanan dan Pengalaman Pelanggan Menggunakan Bahasa Pemograman Python (Studi di Toko Online Produk Makanan Pendamping ASI) [Undergraduated Thesis]. Universitas Gadjah Mada.

Medhat, W., Hassan, A., & Korashy, H. (2014). Sentiment analysis algorithms and applications: A survey. Ain Shams Engineering Journal, 5(4), 1093–1113. https://doi.org/10.1016/j.asej.2014.04.011

Pang, B., & Lee, L. (2008). Opinion mining and sentiment analysis. Foundations and Trends in Information Retrieval, 2(1–2), 1–135. https://doi.org/10.1561/1500000011

Priyanto, A., & Ma'arif, M.R. (2018). Implementasi web scraping dan text mining untuk akuisisi dan kategorisasi indormasi dari internet (Studi kasus: Tutorial hidroponik). Indonesian Journal of Information Systems (IJIS), 1(1), 25-33. https://doi.org/10.24002/ijis.v1i1.1664

Ramos, J. (2003). Using TF-IDF to determine word relevance in document queries. Proceedings of the First Instructional Conference on Machine Learning, 1-4. Diakses dari https://www.scribd.com/document/339224468/TF-IDF-to-determine-word-relevance-in-document-queries-pdf

Shadeni, E.A., & Erinos. (2022). Pengaruh market share dan intellectual capital terhadap kinerja keuangan perbankan syariah di Indonesia. Jurnal Eksplorasi Akuntansi (JEA), 4(2), 363-376. https://doi.org/10.24036/jea.v4i2.531

Siringoringo, R., & Jamaluddin. (2019). Text mining dan klasterisasi sentimen pada ulasan produk toko online. Jurnal Penelitian Teknik Informatika UNPRI, 2(2), 314-319. https://doi.org/10.34012/jutikomp.v2i1.456

Solihin, F., Awaliyah, S., & Shofa, A.M.A. (2021). Pemanfaatan Twitter sebagai media penyebaran informasi oleh dinas komunikasi dan informatika. Jurnal Pendidikan Ilmu Pengetahuan Sosial (JPIPS), 1(13), 52-58. https://e-journal.upr.ac.id/index.php/JP-IPS/article/view/2813

Toffin Indonesia. (2020, November 12). Toffin Indonesia Merilis Riset “2020 Brewing in Indonesia”. Diambil kembali dari TOFFIN INSIGHT: Diakses dari https://insight.toffin.id/toffin-stories/toffin-indonesia-merilis-riset-2020-brewing-in-indonesia/

Wang, J. (2025). Comparative analysis of machine learning and deep learning models for text emotion classification in federated learning. Applied and Computational Engineering, 155, 220-227. https://doi.org/10.54254/2755-2721/2025.GL23568

Zhafira, D.F., Rahayudi, B., & Indriati. (2021). Analisis sentimen kebijakan kampus merdeka menggunakan naive bayes dan pembobotan TF-IDF berdasarkan komentar pada Youtube. Jurnal Sistem Informasi, Teknologi Informasi, dan Edukasi Sistem Informasi (JUST-SI), 2(1), 55-63. https://doi.org/10.25126/justsi.v2i1.24

Downloads

Published

2025-10-16

How to Cite

Pamungkas, A. P., Mahendra, A., & Aziz, I. W. F. (2025). Comparison of Machine Learning Models for Classifying Consumer Sentiment of Coffee Shops on Social Media X. Jurnal Teknik Pertanian Lampung (Journal of Agricultural Engineering), 14(5), 1905–1912. https://doi.org/10.23960/jtepl.v14i5.1905-1912