This study aims to analyze public opinion regarding the policy of limiting the use of Pertalite fuel by examining user comments on the Instagram platform. To classify these opinions, classification approaches using K-Nearest Neighbor (KNN) and Random Forest algorithms were employed. Comments were categorized into three sentiment expressions: positive, negative, and neutral. The research stages included data collection (crawling), text cleaning and normalization, sentiment labeling, weighting using the TF-IDF technique, model development, and performance evaluation. A total of 2,081 comments were used, with 1,000 comments labeled by language experts as training data, and the remaining used for testing. Model evaluation was conducted using two data splitting ratios, 80:20 and 70:30, to assess classification stability and accuracy. The results indicate that the Random Forest algorithm consistently outperforms KNN, achieving the highest accuracy of 73% under the 80:20 scenario. The classification distribution suggests a dominance of negative sentiment in public opinion toward the policy. These findings reflect public dissatisfaction and serve as critical input for the government in reviewing the subsidized fuel distribution policy. This research also highlights the potential of social media as an alternative data source for real-time public perception analysis.
Copyrights © 2025