Article Open Access

Public Sentiment Analisys on the Phenomenom of Body Shaming on Social Media X Using the Extreme Gradient Boosting Algorithm

Nadya Raudathul Sofa, Dahlan Abdullah, Maryana Maryana

Abstract


The phenomenon of body shaming on social media platform X (Twitter) has become increasingly widespread and has caused various psychological impacts on its victims. The high level of social media activity has made the spread of negative comments related to body shape more difficult to control. Therefore, a system capable of automatically performing sentiment analysis is needed to identify public opinions regarding this phenomenon. This study aims to implement the Extreme Gradient Boosting (XGBoost) algorithm in classifying public sentiment toward the body shaming phenomenon on social media X and to determine the sentiment analysis results obtained. The research data were collected using a web scraping technique through Tweet Harvest, resulting in 1,383 Indonesian-language tweets which were manually classified into three sentiment classes: positive, negative, and neutral. The text preprocessing stage included case folding, cleansing, tokenizing, normalization, and filtering without applying stemming, as it was proven to reduce model performance on social media text data. Feature weighting was carried out using the TF-IDF method, while the data were divided using an 80:20 ratio with the implementation of Random Over Sampling (ROS) to address class imbalance. The XGBoost model was built using parameters of n_estimators = 300, learning_rate = 0.05, and max_depth = 5. The evaluation results using a confusion matrix showed an accuracy value of 80.87%, with F1-scores of 0.85 for the negative class, 0.71 for the neutral class, and 0.81 for the positive class. The results indicate that the XGBoost algorithm is capable of classifying public sentiment toward the body shaming phenomenon with fairly good performance. In addition, a web-based sentiment analysis system was successfully implemented to facilitate the automatic and structured sentiment classification process.


Keywords


Body Shaming, Sentiment Analisys, Social Media X, Extreme Gradient Boosting, TF-IDF

References


D. Firdaus, D. Dewi, I. Rusfien, D. Valdiani, and H. Suharyati, “When Body Shaming on Social Media Harms One’s Mental Health, Who’s to Blame?,” 2023, doi: 10.4108/eai.15-9-2022.2335885.

F. Deviantony, Y. Fitria, R. Rondhianto, and N. K. T. Pramesuari, “An in depth review of body shaming phenomenon among adolescent: Trigger factors, psychological impact and prevention efforts,” South African J. Psychiatry, vol. 30, pp. 6–11, 2024, doi: 10.4102/sajpsychiatry.v30i0.2341.

I. Y. Kairupan, A. Angdresey, H. Arif, and K. G. Emor, “An Extreme Gradient Boosting Approach for Classification and Sentiment Analysis,” vol. 16, no. 3, pp. 211–225, 2024, doi: 10.12695/ajtm.2023.16.3.5.

S. Luthfiah and Y. Syahputra, “Examining the Effect of Body Shaming on Adolescent Mental Health,” vol. 1, no. 1, pp. 38–46, 2026, doi: 10.63203/0321049800.

M. Sofiah et al., “The Awareness of the Impact of Body Shaming among Youth The Awareness of the Impact of Body Shaming among Youth,” vol. 12, no. 4, pp. 1096–1110, 2022, doi: 10.6007/IJARBSS/v12-i4/13197.

A. Ligthart, C. Catal, and B. Tekinerdogan, Systematic reviews in sentiment analysis : a tertiary study, vol. 54, no. 7. Springer Netherlands, 2021. doi: 10.1007/s10462-021-09973-3.

K. L. Tan and C. P. Lee, “applied sciences A Survey of Sentiment Analysis : Approaches , Datasets , and Future Research,” 2023.

A. Cas, “A review on sentiment analysis from social media platforms Margarita Rodríguez-Ib a,” vol. 223, no. August 2022, 2023, doi: 10.1016/j.eswa.2023.119862.

V. Çet?n and O. YILDIZ, “A comprehensive review on data preprocessing techniques in data analysis Veri analizinde veri ön i?leme teknikleri üzerine kapsaml? bir inceleme,” vol. 28, no. 2, pp. 299–312, 2022, doi: 10.5505/pajes.2021.62687.

H. T. Duong, T. Anh, and N. Thi, “A review : preprocessing techniques and data augmentation for sentiment analysis,” Comput. Soc. Networks, pp. 1–16, 2021, doi: 10.1186/s40649-020-00080-x.

A. Addiga and S. Bagui, “Sentiment Analysis on Twitter Data Using Term Frequency-Inverse Document Frequency,” pp. 117–128, 2022, doi: 10.4236/jcc.2022.108008.

H. D. Abubakar, M. Umar, and M. A. Bakale, “Sentiment Classification : Review of Text Vectorization Methods : Bag of,” vol. 4, no. 1, pp. 27–33, 2022, doi: 10.56471/slujst.v4i.266.

D. F. Doghramachi and S. Y. Ameen, “Internet of Things ( IoT ) Security Enhancement Using XGboost Machine Learning Techniques,” 2023, doi: 10.32604/cmc.2023.041186.

P. Zhang, Y. Jia, and Y. Shang, “Research and application of XGBoost in imbalanced data,” vol. 18, no. 263, 2022, doi: 10.1177/15501329221106935.

T. Chen and C. Guestrin, “XGBoost: A scalable tree boosting system,” Proc. ACM SIGKDD Int. Conf. Knowl. Discov. Data Min., vol. 13-17-Augu, no. August 2016, pp. 785–794, 2016, doi: 10.1145/2939672.2939785.

S. Sathyanarayanan and B. R. Tantri, “Confusion Matrix-Based Performance Evaluation Metrics,” vol. 27, no. 4, 2024, doi: 10.53555/AJBR.v27i4S.4345.

J. Li, H. Sun, and J. Li, “Beyond confusion matrix : learning from multiple annotators with awareness of instance features,” Mach. Learn., vol. 112, no. 3, pp. 1053–1075, 2023, doi: 10.1007/s10994-022-06211-x.

M. R. Kurniawanda, F. Adline, T. Tobing, and P. S. Informatika, “Analysis Sentiment Cyberbullying in Instagram Comments with XGBoost Method,” vol. 9, no. 1, 2022, doi: 10.31937/ijnmt.v9i1.2670.

A. Gumaei, C. Computer, and I. Sciences, “An Effective Approach for Rumor Detection of Arabic,” vol. 21, no. 1, pp. 1–16, 2022, doi: 10.1145/3461697.

F. Alzamzami and M. Hoda, “Light Gradient Boosting Machine for General Sentiment Classification on Short Texts : A Comparative Evaluation,” vol. 8, 2020, doi: 10.1109/ACCESS.2020.2997330.




DOI: https://doi.org/10.52088/ijesty.v6i2.1818

Refbacks

  • There are currently no refbacks.


Copyright (c) 2026 Nadya Raudathul Sofa, Dahlan Abdullah, Maryana Maryana

International Journal of Engineering, Science, and Information Technology (IJESTY) eISSN 2775-2674