MATLAB implementation of online-learning experiments for drift-aware anomaly detection in skewed data streams, developed alongside:
E. Mahmodi, H. S. Yazdi, A. G. Bafghi (2020). "A drift aware adaptive method based on minimum uncertainty for anomaly detection in data stream with skewed distribution." Expert Systems with Applications, Elsevier.
This repository builds on the LIBOL toolbox (Steven C.H. Hoi et al., 2012) for its panel of comparison algorithms:
algorithms/ALMA.m,PA.m,PA1.m,PA2.m,Perceptron.m,ROMMA.m,aROMMA.m,OGD.m,SOP.m,CW.m,AROW.m,NAROW.m,NHERD.m,SCW.m,SCW2.m,IELLIP.mare LIBOL's implementations, each carrying a@LIBOL 2012 Contact: chhoi@ntu.edu.sgattribution header in the source. These are well-known, published online-learning algorithms (Perceptron, Passive-Aggressive, Confidence-Weighted learning, AROW, etc.) used here purely as a comparison panel, not as this project's contribution.
The original contribution of this work is the fusion strategy, implemented
in run_experiment_bc.m (the weight-computation block) and algorithms/Dr_Sadoghi.m
(the weighted linear combiner): predictions from the panel of baseline learners
above are combined with weights inversely proportional to each learner's
prediction-error variance, so that learners with more stable, confident
behaviour on the stream so far get more say in the final decision. This is the
"minimum uncertainty" method referenced in the paper title.
If you are evaluating this code (e.g. as part of a job or research application), please attribute the baseline algorithms to LIBOL and treat the fusion/weighting logic as the demonstrated original contribution.
``` algorithms/ Baseline online learners (LIBOL) + Dr_Sadoghi.m (fusion combiner) data/ Datasets used in experiments (phishing/URL and network-traffic features) result/ Example output logs from experiment runs run_experiment_bc.m Main experiment script: runs all baselines + the minimum-uncertainty fusion init.m, init_model.m, init_options.m Setup / hyperparameter configuration for each algorithm calculateError.m, my_validation.m Evaluation metrics (accuracy, F-score, MCC, RMSE, etc.) ```
See also the Python port of this codebase, which reimplements the same baseline/fusion split with an accompanying test suite.
```matlab run_experiment_bc ```
This loads a dataset from data/, runs each baseline algorithm plus the
minimum-uncertainty fusion over the stream, and writes per-algorithm accuracy /
F-score / MCC / RMSE logs to the working directory (mirroring the files in
result/).
The baseline algorithms under algorithms/ (all files carrying the @LIBOL
header) are from the LIBOL toolbox by Steven C.H. Hoi et al. — see COPYING
for LIBOL's license terms. The fusion method (Dr_Sadoghi.m and the weighting
logic in run_experiment_bc.m) is original work by the repository author.