Real-time detection of N2 and N3 sleep from scalp and intracranial EEG

Sleep rhythms such as slow oscillations and spindles arise predominantly during N2 and N3 sleep (N2+N3). Closed-loop stimulation targeting these rhythms is a promising strategy to enhance memory. Such stimulation requires online sleep stage classification. Conventional staging labels completed 30-s epochs using past and future data and cannot support online staging. We developed a causal tracker that, every 2 s, estimates the current stage from the preceding 10 s of scalp or intracranial EEG. We also evaluated a simulated rule that permits stimulation after three consecutive estimates indicating N2+N3 sleep. In six adults with drug-resistant epilepsy with simultaneous scalp EEG and stereo-EEG, real-time N2+N3 discrimination remained close to offline scoring of the same recordings (scalp AUC 0.953 versus 0.958). Thalamic channels alone reached AUC 0.934 and exceeded mesial temporal channels in every patient, and scalp plus thalamus performed best (0.967). The scalp tracker, retrained in 28 healthy adults, reached 0.976. When patients transitioned into N2+N3 sleep with stimulation initially disabled, the rule permitted stimulation within 5 min in 63-73% of transitions, with a median delay of 42-64 s among those detected. After leaving N2+N3, stimulation was disabled after a median of 19-22 s. The rule also switched on incorrectly 1.4-1.8 times per hour outside N2+N3 and remained active during 28-31% of REM in patients, compared with 2% in healthy adults. These findings show that both scalp and thalamic EEG can support real-time N2+N3 detection and inform when stimulation is permitted. Translationally, implanted thalamic leads, increasingly used for neuromodulation in epilepsy, could support sleep-stage-dependent stimulation without scalp EEG, while scalp EEG might be used for noninvasive neuromodulation. Closed-loop systems should be evaluated not only by sleep-stage classification accuracy but also by how reliably and promptly they enable and disable stimulation.

Authors

Institutions

Publication Details

Journal
bioRxiv (Cold Spring Harbor Laboratory)
Published
2026-11-06
DOI
https://doi.org/10.64898/2026.11.05.764694
Primary Topic
EEG and Brain-Computer Interfaces
Type
preprint
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
NOV
preprint

Real-time detection of N2 and N3 sleep from scalp and intracranial EEG

Paola Malerba, Wim van Drongelen, David I. Satzer, Joel L. Voss et al.
4 links
bioRxiv (Cold Spring Harbor Laboratory)
EEG and Brain-Computer Interfaces
preprint

Real-time detection of N2 and N3 sleep from scalp and intracranial EEG

Paola Malerba, Wim van Drongelen, David I. Satzer, Joel L. Voss, Joshua Jacobs, Peter C. Warnke, Mahmoud Alipour, Naoum P. Issa, Kenneth Lee
preprint en

Abstract

Sleep rhythms such as slow oscillations and spindles arise predominantly during N2 and N3 sleep (N2+N3). Closed-loop stimulation targeting these rhythms is a promising strategy to enhance memory. Such stimulation requires online sleep stage classification. Conventional staging labels completed 30-s epochs using past and future data and cannot support online staging. We developed a causal tracker that, every 2 s, estimates the current stage from the preceding 10 s of scalp or intracranial EEG. We also evaluated a simulated rule that permits stimulation after three consecutive estimates indicating N2+N3 sleep. In six adults with drug-resistant epilepsy with simultaneous scalp EEG and stereo-EEG, real-time N2+N3 discrimination remained close to offline scoring of the same recordings (scalp AUC 0.953 versus 0.958). Thalamic channels alone reached AUC 0.934 and exceeded mesial temporal channels in every patient, and scalp plus thalamus performed best (0.967). The scalp tracker, retrained in 28 healthy adults, reached 0.976. When patients transitioned into N2+N3 sleep with stimulation initially disabled, the rule permitted stimulation within 5 min in 63-73% of transitions, with a median delay of 42-64 s among those detected. After leaving N2+N3, stimulation was disabled after a median of 19-22 s. The rule also switched on incorrectly 1.4-1.8 times per hour outside N2+N3 and remained active during 28-31% of REM in patients, compared with 2% in healthy adults. These findings show that both scalp and thalamic EEG can support real-time N2+N3 detection and inform when stimulation is permitted. Translationally, implanted thalamic leads, increasingly used for neuromodulation in epilepsy, could support sleep-stage-dependent stimulation without scalp EEG, while scalp EEG might be used for noninvasive neuromodulation. Closed-loop systems should be evaluated not only by sleep-stage classification accuracy but also by how reliably and promptly they enable and disable stimulation.

bioRxiv (Cold Spring Harbor Laboratory)
Nationwide Children's Hospital (US), University of Chicago (US), Abigail Wexner Research Institute (US), The Ohio State University (US)
Good health and well-being
EEG and Brain-Computer Interfaces
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon