Mendeteksi Unsur Depresi pada Unggahan Media Sosial Menggunakan Metode Machine Learning dengan Optimasi Berbasis Inspirasi Alam
DOI:
https://doi.org/10.20956/ejsa.v6i2.45516Keywords:
depression, Social Media, Machine Learning, Feature Selection, Flamingo Search Algorithm, Text ClassificationAbstract
Social media has now become an inseparable part of everyday life, including in expressing emotions and mental states. One popular platform is X (formerly Twitter), where many users indirectly share signs of depression. This study develops a classification model to detect indications of depression in social media posts, using machine learning algorithms and feature selection techniques based on nature-inspired algorithms. The classification algorithms used include Naïve Bayes, k-Nearest Neighbors (k-NN), Decision Tree, Random Forest, and XGBoost. Each algorithm is combined with feature selection techniques using Particle Swarm Optimization (PSO), Bat Algorithm (BA), and Flamingo Search Algorithm (FSA). The models are evaluated based on accuracy, precision, recall, F1-score, and the number of features used. The results show that the combination of the Random Forest method with FSA-based feature selection (RF-FSA) delivers the best performance, with an accuracy of 82.2%, balanced precision and recall, and efficient feature usage. Another strong alternative is XGBoost with FSA (XGB-FSA), although it requires more features and longer computational time. This study demonstrates that selecting the right feature selection algorithm, particularly FSA, can significantly improve both the accuracy and efficiency of depression text classification models. The resulting model is expected to serve as a useful tool for early detection of depression symptoms from social media posts, allowing for quicker and more targeted interventions.
References
Cahyono, A. S. Pengaruh Media Sosial Terhadap Perubahan Sosial Masyarakat Di Indonesia. Publiciana, 9, 140–157, 2016.
Zsila, Á., Reyes, M. Pros & cons: impacts of social media on mental health. BMC Psychol, 11(1), 201, 2023. doi:10.1186/s40359-023-01243-x.
Ridlo, I. A. Pandemi COVID-19 dan Tantangan Kebijakan Kesehatan Mental di Indonesia. INSAN Jurnal Psikologi dan Kesehatan Mental, 5(2), 162–171, 2020. doi : 10.20473/jpkm.V5I22020.162-171.
Muslimahayati, M., & Rahmy, H. A. Depresi dan Kecemasan Remaja Ditinjau dari Perspektif Kesehatan dan Islam. DEMOS: Journal of Demography, Ethnography and Social Transformation, 2021.
Brody, H. A journey into the causes and effects of depression. Nature, 608(7924), S35–S35, 2022.
Nurrochman, M. M., Prasasti A. I., & Nugrahaeni, R. A. Implementasi Machine Learning Untuk Mendeteksi Unsur Depresi Pada Tweet Menggunakan Metode NaÏve Bayes. eProceedings of Engineering, 8, 6250–6257, 2021.
Dainamang, S. A., Hayatin, N., & Chandranegara, D. R. Analisis Sentimen Media Sosial Twiiter terhadap RUU Omnibus Law dengan Metode Naive Bayes dan Particle Swarm Optimization. Komputika : Jurnal Sistem Komputer, 11(2), 211–218, 2022. doi:10.34010/komputika.v11i2.6037.
Yang, X. S. A New Metaheuristic Bat-Inspired Algorithm. Di dalam: González JR, Pelta DA, Cruz C, Terrazas G, Krasnogor N, editor. Nature Inspired Cooperative Strategies for Optimization (NICSO 2010). Berlin, Heidelberg: Springer Berlin Heidelberg, 65–74, 2010.
Zhiheng, W., & Jianhua, L. Flamingo Search Algorithm: A New Swarm Intelligence Optimization Algorithm. IEEE Access, 9,88564–88582, 2021. doi:10.1109/ACCESS.2021.3090512.
Dirgayunita, A. Depresi: Ciri, Penyebab dan Penangannya. Journal An-Nafs: Kajian Penelitian Psikologi, 1(1), 1–14, 2016. doi:https://doi.org/10.33367/psi.v1i1.235.
Hadi, I., Wijayanti, F., Devianti, R., & Rosyanti, L. GANGGUAN DEPRESI MAYOR (MAYOR DEPRESSIVE DISORDER) MINI REVIEW. Health Information : Jurnal Penelitian, 9, 25–40, 2017. doi:10.36990/hijp.v9i1.102.
Nasukawa, T., & Yi, J. Sentiment Analysis: Capturing Favorability Using Natural Language Processing. Proceedings of the 2nd International Conference on Knowledge Capture, 2003.
Liu, X., dkk. SocialCube: A text cube framework for analyzing social media data. Di dalam: Proceedings of the 2012 ASE International Conference on Social Informatics, SocialInformatics 2012. IEEE Computer Society, 252–259, 2012.
Freitas, D., Lopes, L. G., & Morgado-Dias F. Particle Swarm Optimisation: A Historical Review Up to the Current Developments. Entropy, 22(3), 2020. doi:10.3390/e22030362
Yang, X. Nature-Inspired Optimization Algorithms. Di dalam: Yang X-S, editor. Nature-Inspired Optimization Algorithms. Oxford: Elsevier, 2014.
Downloads
Published
Issue
Section
License
Copyright
It is the author's responsibility to ensure that his or her submitted work does not infringe any existing copyright. Authors should obtain permission to reproduce or adapt copyrighted material and provide evidence of approval upon submitting the final version of a manuscript.
