This site maintains the scripts and the toolbox SPA for:
Ouyang, G., Dien, J., & Lorenz, R. (2021). Handling EEG artifacts and searching individually optimal experimental parameter in real time: a system development and demonstration. Journal of Neural Engineering.
author's preprint: https://github.com/guangouyang/spa/blob/main/SPA1.0/documentation/SPA_manuscript_author_preprint.pdf