Analysis classifies customer loyalty levels using decision tree and KNN methods, suggesting effective sales strategies.
Customer loyalty is a crucial element in maintaining business continuity in today’s competitive digital era. This study aims to classify customer loyalty levels based on sales and transaction behavior data using two supervised machine learning algorithms: K-Nearest Neighbor (KNN) and Decision Tree. The models were developed and evaluated using Python in the Google Colaboratory environment, utilizing a dataset of 250 customer records. The research process included data preprocessing, feature selection, normalization, data splitting, model building, and evaluation using accuracy, precision, recall, and F1-score metrics. Evaluation results showed that the Decision Tree algorithm delivered the best performance with 99.20% accuracy, 99.50% precision, 99.50% recall, and a 99.50% F1-score. Meanwhile, the KNN algorithm achieved 91.60% accuracy, 91.63% precision, 98.50% recall, and a 94.91% F1-score. These findings indicate that the Decision Tree model is more effective for classifying customer loyalty and can be implemented as a decision support tool for data-driven Customer Relationship Management (CRM) strategies.
No takes yet. Share an insight, caveat, or question.
Mukhlisin et al. (2025) studied this question.
Synapse has enriched 2 closely related papers on similar clinical questions. Consider them for comparative context: