Robust Oversampling with RM-SMOTE for Imbalanced Classification

Provides the ROBOSRMSMOTE (Robust Oversampling with RM-SMOTE) framework for imbalanced classification tasks. This package extends Mahalanobis distance-based oversampling techniques by integrating robust covariance estimators to better handle outliers and complex data distributions. The implemented methodology builds upon and significantly expands the RM-SMOTE algorithm originally proposed by Taban et al. (2025) .


ROBOSRMSMOTE

R License

Overview

ROBOSRMSMOTE (Robust Oversampling with RM-SMOTE) provides a framework for imbalanced classification tasks. This package extends Mahalanobis distance-based oversampling techniques by integrating robust covariance estimators to better handle outliers and complex data distributions. The implemented methodology builds upon and significantly expands the RM-SMOTE algorithm originally proposed by Taban et al. (2025).

Seven robust covariance estimators are supported.

Taban, R., Nunes, C. and Oliveira, M.R. (2025). RM-SMOTE: a new robust balancing technique. Statistical Methods & Applications. https://doi.org/10.1007/s10260-025-00819-8


Installation

install.packages("ROBOSRMSMOTE")

Core Functions

Function Description
ROBOS_RM_SMOTE() Main function — generates synthetic minority observations
weighting() Computes robust Mahalanobis weights for minority class
get_robust_cov() Fits one of 7 robust covariance estimators

Supported Covariance Estimators

cov_method Estimator
"mcd" Minimum Covariance Determinant (default)
"mve" Minimum Volume Ellipsoid
"mest" M-estimator
"mmest" MM-estimator
"sde" Stahel-Donoho Estimator
"sest" S-estimator
"ogk" Orthogonalized Gnanadesikan-Kettenring

Quick Start

library(ROBOSRMSMOTE)

# Load the example dataset (haberman: IR ≈ 2.78, n = 306)
data(haberman)
table(haberman$class)
#> negative positive
#>      225       81

# Balance with ROBOS_RM_SMOTE using MCD (default)
balanced <- ROBOS_RM_SMOTE(dt = haberman, target = "positive", eIR = 1)
table(balanced$class)
#> negative positive
#>      225      225

# Use a different robust estimator
balanced_ogk <- ROBOS_RM_SMOTE(dt     = haberman,
                                target = "positive",
                                eIR    = 1,
                                cov_method  = "ogk",
                                weight_func = 2)   # omega_B weighting
table(balanced_ogk$class)

Weighting Functions

weight_func Formula Behaviour
1 ω_A: weight = 0 Hard exclusion of outliers
2 ω_B: weight = 1/MD² Soft down-weighting
3 ω_C: weight = τ/MD² Minimal down-weighting

License

GPL-3 © Emre Dunder, Mehmet Ali Cengiz, Zainab Subhi Mahmood Hawrami, Abdulmohsen Alharthi

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("ROBOSRMSMOTE")

1.0.0 by Zainab Subhi Mahmood Hawrami, 7 months ago


Browse source code at https://github.com/cran/ROBOSRMSMOTE


Authors: Emre Dunder [aut] , Mehmet Ali Cengiz [aut] , Zainab Subhi Mahmood Hawrami [aut, cre] , Abdulmohsen Alharthi [aut]


Documentation:   PDF Manual  


GPL-3 license


Imports rrcov, meanShiftR, stats

Suggests testthat, knitr, rmarkdown


See at CRAN