Clustering-Based Undersampling Using K-Means for Class-Imbalanced Data

This paper presents a data-level clustering-based undersampling method that uses k-means with nearest-centroid selection to rebalance severely imbalanced datasets before SVM classification. Rather than discarding majority samples at random, the method partitions the majority class into k clusters (k = minority-class size N) and retains the real sample nearest each centroid, preserving majority-class coverage while matching the minority size. Validated on the Protein Homology Prediction dataset (imbalance ratio 111.46:1), the balanced configuration (k = N) achieves 96.5% accuracy, 97.6% recall, 97.7% specificity, and a 96.4% F1-score, with the misclassification rate minimized at 3.5%. A per-metric sensitivity analysis over k clarifies how the undersampling ratio controls the precision–recall trade-off.