This Matlab code demonstrates how to implement slow and fast sigma peak detection based on generalized eigendecomposition, as described in the following paper:
R Cox, AC Schapiro, DS Manoach, R Stickgold, Front. Hum. Neurosci.11 (2017), doi:10.3389/fnhum.2017.00433.
exampleSigmaPeakGED.m is the main script
*.set files hold multichannel EEG sleep records in EEGlab format of three subjects (N2 and N3 separate)
vline.m is a helper file for drawing vertical lines