The method of using deep learning technology to realize automatic sleep staging needs a lot of data support, and its computational complexity is also high. In this paper, an automatic sleep staging method based on power spectral density (PSD) and random forest is proposed. Firstly, the PSDs of six characteristic waves (K complex wave, δ wave, θ wave, α wave, spindle wave, β wave) in electroencephalogram (EEG) signals were extracted as the classification features, and then five sleep states (W, N1, N2, N3, REM) were automatically classified by random forest classifier. The whole night sleep EEG data of healthy subjects in the Sleep-EDF database were used as experimental data. The effects of using different EEG signals (Fpz-Cz single channel, Pz-Oz single channel, Fpz-Cz + Pz-Oz dual channel), different classifiers (random forest, adaptive boost, gradient boost, Gaussian naïve Bayes, decision tree, K-nearest neighbor), and different training and test set divisions (2-fold cross-validation, 5-fold cross-validation, 10-fold cross-validation, single subject) on the classification effect were compared. The experimental results showed that the effect was the best when the input was Pz-Oz single-channel EEG signal and the random forest classifier was used, no matter how the training set and test set were transformed, the classification accuracy was above 90.79%. The overall classification accuracy, macro average F1 value, and Kappa coefficient could reach 91.94%, 73.2% and 0.845 respectively at the highest, which proved that this method was effective and not susceptible to data volume, and had good stability. Compared with the existing research, our method is more accurate and simpler, and is suitable for automation.
Citation: GAO Qunxia, WU Kai. Automatic sleep staging based on power spectral density and random forest. Journal of Biomedical Engineering, 2023, 40(2): 280-285, 294. doi: 10.7507/1001-5515.202207047 Copy