TIN: TERAPAN INFORMATIKA NUSANTARA
Vol 5 No 10 (2025): March 2025

Analisis Sentimen Kinerja Lembaga Legislatif di Indonesia Menggunakan Algoritma Random Forest Berbasis Data Media Sosial X

Saputra, Imam (Unknown)
Rahim, Robbi (Unknown)



Article Info

Publish Date
31 Mar 2025

Abstract

Legislative institutions such as the DPR RI are often the center of public attention and criticism on social media, particularly the X platform (formerly Twitter). The high volume of public opinion necessitates an automated classification system to monitor public perception efficiently. This study aims to analyze public sentiment towards the DPR RI in January 2025 using the Random Forest algorithm. A total of 699 tweets were collected via crawling techniques and processed through preprocessing stages including cleansing, folding, normalization, filtering, and stemming. Text features were extracted using the Term Frequency-Inverse Document Frequency (TF-IDF) method. Distribution results show a dominance of the neutral class (73.5%), followed by negative (22.2%) and positive (4.3%) sentiments. Model testing using a confusion matrix demonstrates that the Random Forest algorithm achieves high performance with an accuracy rate of 96.43%. Feature importance analysis reveals that profanity and integrity issues such as "corruption" are the primary indicators of negative sentiment. This study concludes that Random Forest is highly reliable in classifying public opinions with strong emotional polarity on social media.

Copyrights © 2025