World Sleep Industry ENCYCLOPEDIA

EEG sleep staging annotation data

4.4.3

Definition, Uses, and Scope

EEG sleep staging annotation data combine continuous electroencephalography with time-aligned labels for wakefulness, non-rapid-eye-movement sleep, and rapid-eye-movement sleep, plus the recording and scoring metadata needed to interpret them. The data can support sleep-architecture research, scorer education, automated staging development, quality control, and methodological reproduction. Common deliverables include whole-night EEG, epoch-level segments, a stage sequence or hypnogram, and information about participants, nights, and recording conditions.

This resource is not the same as a complete PSG annotation set, and not every label was necessarily produced from EEG alone. Clinical staging often incorporates electrooculography, chin electromyography, respiratory events, arousals, and the context of preceding and following epochs, even when an algorithm receives only one EEG derivation. A dataset should state which signals were visible to the scorer and whether model inputs match the signals used to generate the reference. Labels are reference interpretations under specified rules and evidence, not unconditionally correct physiological truth.

EEG Signals, Derivations, and Preprocessing

EEG meaning depends on electrode placement, reference electrode or bipolar derivation, polarity, sampling rate, amplitude units, gain, analog and digital filters, calibration, and electrode quality. Channels with apparently similar names may use different references and therefore have different spectra and waveform amplitudes. Documentation should give the actual derivation expression, device and amplifier, acquisition settings, impedance or quality records, and distinguish original channels, re-referenced channels, and standardized channels created by an algorithm.

Preprocessing may include resampling, band-pass or notch filtering, detrending, amplitude clipping, artifact suppression, normalization, and segment exclusion; each step can alter sleep features. Publishers should retain a raw or closest-to-raw release and record parameters, software, and operation order. Irreversible cleaning should not be summarized only as “denoising.” Missing data, flat lines, saturation, motion, detached electrodes, and device removal need separate quality flags and must not be hidden by zero-filled arrays that merely have a convenient shape.

Stage Labels, Epochs, and Temporal Meaning

Contemporary adult data commonly assign W, N1, N2, N3, and R to fixed-duration epochs, while unscored, unknown, movement-time, or artifact states may also occur. The annotation file must define epoch duration, the time origin of the first epoch, boundary rules, treatment of a final partial epoch, and whether labels are points, intervals, or block classes. A hypnogram represents the sequence of stages over time but generally does not include every arousal, respiratory event, or movement event and must not be mistaken for a complete sleep-study annotation.

Whole-night files are often trimmed to remove wake before sleep onset or after final awakening in order to control class balance or file size. This changes sleep efficiency, transition probabilities, and algorithm difficulty. A dataset should preserve the original recording interval, trimming rule, and removed duration, and distinguish unscored, unscorable, outside the analysis window, and a genuine stage. If sliding windows or context sequences form samples, handling at stage transitions, night boundaries, and missing intervals must also be documented.

Scoring Systems, Versions, and Cross-dataset Harmonization

Sleep-staging rules have changed across historical periods and manual editions. Legacy data may separate deep sleep into stages 3 and 4 or include states absent from a current taxonomy; simply renaming them can discard meaning. Harmonization should retain the original label and scoring system and add an explicit mapped field that records merges, exclusions, and non-convertible cases. Pediatric, infant, or special populations may use different rules, so an adult stage set must not be imposed without qualification on every age group.

Scoring provenance should include the rule edition, scoring software, display filters, channels shown, scorer identity or qualification, automated prescoring, human review, blinding, and edit history. Sources also require harmonization or explicit separation of units, channel names, references, polarity, sampling, timestamps, and label vocabulary. A release should carry file checksums, a data dictionary, sample manifest, change log, and known issues so that researchers can reproduce the snapshot and distinguish original annotations, harmonized labels, and later corrections.

Signal Quality, Scorer Variation, and Label Uncertainty

Staging reliability depends on both the signal and human judgment. Low-amplitude EEG, brief phenomena, stage transitions, artifacts, and limited derivations create borderline cases for which scorers can disagree. A dataset should retain multiple-scorer results, adjudication or consensus procedures, agreement statistics, and the unscored fraction when available. If only one final label is released, its origin—single scorer, expert review, vote, or automated system—should still be stated. Consensus can improve consistency but does not turn a label into unquestionable truth.

Quality checks should verify agreement among signal and annotation counts, start times, duration, and clocks; inspect waveforms against declared units and polarity; and detect duplicate recordings, mismatched hypnograms, and global time shifts. Label distributions should be reviewed by participant, night, age, condition, device, and center. Data from one laboratory or specialty clinic can reflect referral, medication, first-night, and collection-era effects. A large number of adjacent epochs cannot substitute for independent participants or coverage of the target population.

Machine-learning Splits, Evaluation, and Reproducibility

Algorithm datasets should split training, validation, and testing by participant so that a person's different nights, neighboring epochs, re-exported copies, and derived channels stay in the same partition. Random epoch splitting leaks individual characteristics and strong temporal correlation. Normalization statistics, artifact thresholds, class resampling, and model selection must use training information only. Validation data serve tuning, while test labels remain sealed, and external validation should where possible span other centers, devices, and populations.

Overall accuracy can be dominated by common stages, so reports should also include per-class sensitivity or recall, precision, confusion patterns, macro-averaged measures, agreement measures, and uncertainty intervals, with separate analysis of transitions, poor signals, and minority classes. Model comparisons require the same scoring system, trimming interval, and participant partitions. The data release, inclusion manifest, software dependencies, random seeds, preprocessing, and postprocessing must be preserved. A system should not be revised after repeatedly inspecting test labels.

Privacy, Access Governance, and Clinical Limits

EEG and whole-night temporal structure may carry individual characteristics, and files can also contain dates, age, device identifiers, sites, free text, or linked clinical information. Publishers should perform data minimization, de-identification, and re-identification risk assessment consistent with consent and applicable rules, using open, application-based, or controlled access according to sensitivity. Users must protect downloaded copies, tokens, and model-derived artifacts; follow licensing and restrictions on re-identification or redistribution; and apply required handling when access expires, a withdrawal applies, or a mismatch is found.

Automated staging can support research and workflows, but a stage label does not diagnose a sleep disorder or independently determine treatment. Agreement with reference scoring does not prove clinical benefit or suitability for every population. Deployment additionally requires validation of input devices, signal quality, failure detection, human review, and applicable regulatory requirements. A mature dataset lets users trace every stage label to its signals, rules, scorers, and release while clearly marking evidentiary gaps and contexts in which it should not be used.