Combined Resampling Strategies
What you'll learn: How to use both oversampling and undersampling together to balance your dataset more effectively than either method alone.
The Best of Both Worlds
You've learned about oversampling the minority class (creating more examples of rare cases) and undersampling the majority class (removing some common examples). But here's the insight: you don't have to choose just one!
Combined resampling strategies apply both techniques together to find a sweet spot between data quantity and class balance.
Why Combine?
Think of it like adjusting both brightness and contrast on a photo—one control alone might not give you the perfect image.
- Only oversampling? You might end up with a bloated dataset and overfitting to synthetic examples.
- Only undersampling? You lose potentially valuable information from discarded majority samples.
- Both together? You moderately increase minority samples while moderately decreasing majority samples, maintaining a reasonable dataset size while achieving better balance.
How It Works
The typical approach:
- Apply SMOTE or another oversampling technique to the minority class (but don't go all the way to 50/50)
- Apply undersampling to the majority class (but don't remove too aggressively)
- Aim for a balanced ratio (e.g., 40:60 or 45:55) with a manageable total size
For example, if you have 100 minority and 10,000 majority samples:
- Oversample minority to 500 (using SMOTE)
- Undersample majority to 1,000
- Result: 500:1,000 ratio with 1,500 total samples
This hybrid approach preserves training data diversity while correcting class imbalance.
Key Takeaway: Combined resampling strategies blend oversampling and undersampling to balance class ratios while maintaining reasonable dataset size and information content, often outperforming either technique used alone.