Sentiment analysis of product reviews offers valuable insights into consumer perspectives, which can inform product development and marketing strategies. Given the growing importance of user-generated content like product reviews, this study explored sentiment classification in online reviews of Ben & Jerry's ice cream. We designed and evaluated three machine learning algorithms for sentiment classification: Naïve Bayes (NB), logistic regression (LR), and support vector machine (SVM). The dataset exhibited a significant class imbalance, with substantially more positive than negative reviews. We employed two oversampling techniques: the synthetic minority oversampling technique (SMOTE) and the adaptive synthetic sampling approach (ADASYN). With the original skewed data, NB, LR, and SVM achieved accuracies of 91.90%, 93.77%, and 95.09%, respectively. While SMOTE did not improve performance in some scenarios, ADASYN yielded positive results and generally enhanced model reliability across all algorithms. Post-balancing with ADASYN, the sentiment distribution became less skewed, and accuracies shifted to 92.04% for NB, 94.96% for LR, and 95.23% for SVM. The combination of SVM and ADASYN demonstrated promising results, suggesting this approach may offer robust and efficient performance for binary sentiment classification, especially with imbalanced datasets.
Copyrights © 2025