Skip to content

New Code Proposal: Add ARMBR blink artifact removal method to mne.preprocessing #13324

@ludvikalkhoury

Description

@ludvikalkhoury

Describe the new feature or enhancement

I propose adding a new blink artifact removal method called Artifact-Reference Multivariate Backward Regression (ARMBR) to the mne.preprocessing module.

Key features:
-Removes blinks via multivariate linear regression using a binarized blink reference
-Works with minimal training data
-Requires no EOG channels
-Supports both offline and real-time/BCI pipelines
-Fully integrated with MNE: .fit(), .apply(), and .plot() methods using Raw objects

This method is described in the paper:
Alkhoury, L., Scanavini, G., Louviot, S., Radanovic, A., Shah, S. A., & Hill, N. J. (2025). Artifact-reference multivariate backward regression (ARMBR): A novel method for EEG blink artifact removal with minimal data requirements. Journal of Neural Engineering, 22(3), 036048. https://doi.org/10.1088/1741-2552/ade566

The code is MNE-compatible and includes:
-A class ARMBR for MNE pipelines
-Full test coverage using mne.datasets.sample
-Documentation and plotting utilities
-Example scripts for integration

I am happy to submit this toolbox as a PR for inclusion in mne.preprocessing.

Thanks for considering this contribution!

Describe your proposed implementation

The proposed feature would be implemented as a new class called ARMBR, located in the mne.preprocessing module (e.g., mne/preprocessing/armbr.py), similar to the structure used for ICA and rASR.

The class would expose the following methods:
-.fit(raw, ...): trains the projection matrix using EEG segments from raw data
-.apply(raw, ...): applies blink artifact suppression to the raw data in-place
-.plot(): visualizes EEG on before/after suppression
-.plot_blink_patterns(): visualizes spatial blink components via topomap

In addition:
-The class is fully compatible with MNE Raw objects and uses Annotations (e.g., armbr_fit) to define training segments.
-The underlying core function run_armbr() will be included in the same module for modular use.
-A dedicated test file (test_armbr.py) using MNE's sample dataset is included.

Let me know if the maintainers prefer a different naming convention or integration strategy.

Describe possible alternatives

A similar implementation is available in the GitHub repository (https://github.com/S-Shah-Lab/ARMBR) that accompanied the original publication of the paper. The proposed integration refactors that version to align with MNE’s coding standards, interface conventions, and documentation style.

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions