# Multi-Class Sleep Stage Analysis and Adaptive Pattern Recognition
## 4 Conclusions  
This paper presents a method involving multi-class classification applied to the recognition of sleep stages using a two layer neural network with the sigmoidal and the softmax transfer functions to  
Figure 8: Results of the training process presenting (**a**) the accuracy and (**b**) the performance of the resulting model for different sleep disorders for sets of male and female individuals using EEG (F5) and multimodal EEG, Flow and OCG (F12) features. \begin{table}
\begin{tabular}{l l l l l l l} \hline \hline \multirow{2}{*}{_Sex_} & \multicolumn{2}{c}{_Accuracy (\%)_} & \multicolumn{2}{c}{_10-Fold Cross-Valid._} & \multirow{2}{*}{_Class_} & \multicolumn{2}{c}{_Precision (\%)_} \\ \cline{2-2} \cline{5-7}  & **F5** & **F12** & **F5** & **F12** & **F5** & **F12** \\ \hline Male & 89.9 & 90.7 & 0.15 & 0.11 & Class 1: Wake & 87.0 & 87.8 \\ Female & 87.6 & 88.5 & 0.17 & 0.14 & Class 2: NonREM & 91.5 & 92.2 \\ _Mean_ & 88.7 & 89.6 & 0.16 & 0.12 & Class 3: REM & 78.6 & 80.5 \\ \hline \hline \end{tabular}
\end{table} 
Table 8: Classification accuracy and the 10-fold cross-validation errors of the sets of males and females and precision of individual classes over all sleep disorders for 5 (F5) mean EEG power features and 12 (F12) features with an additional 4 features evaluated from the flow and electro-oculogram channels. Figure 7: Target and predicted classes of three selected patients with sleep apnea classified by the adaptive neural network model into three classes including (**a**) class 1 (Wake); (**b**) class 2 (NonREM); and (**c**) class 3 (REM) together with (**d**) associated ROC characteristics. evaluate the probabilities of the output classes. The training set includes overnight PSG records of 184 individuals forming an own database acquired and classified by the authors. The proposed method allows the construction of a neural network and its training to recognize sleep stages with a mean classification accuracy of 88.7% (STD: 2.1) specified in Tables 6 and 8 for selected spectral features of the single EEG channel. The accuracy increased to 89.6% (STD: 1.9) for multimodal features obtained from EEG, flow and EOG channels was not too high, probably owing to the presence of corresponding artifacts in the EEG channels. The mean 10-fold cross-validation error decreased from 0.16 (for 5 EEG features) to 0.12 (for 12 multimodal features). The novel approach of the proposed method is the possibility of constructing a mathematical model incorporating the individual experience of a neurologist, allowing a data classification close to his previous strategy and an adaptive modification of model coefficients. Results obtained are compared with selected existing methods in Table 9. The accuracy of sleep stages classification is generally between 70% and 92% [22] and the accuracy of the current model is close to the upper limit of this range. It is projected that the neural network model will be further used for more extensive datasets and adaptation of the results to the experience of the neurologist to reduce the time necessary for manual classification. A special attention will be paid to deep convolutional neural networks [17; 18] that allow row data processing without specification of separate features. [PERSON] was responsible for the mathematical and algorithmic tools allowing the data processing, [PERSON] was responsible for PSG data acquisition, [PERSON] interpreted the acquired data and results obtained from the neurological point of view, [PERSON] contributed to the data preprocessing, [PERSON] contributed to interpretation of results from the neurology point of view and [PERSON] was responsible for computational processing and visualization. All authors have read and approved the final manuscript. Real data were kindly provided by the Department of Neurology of the Faculty Hospital of the Charles University in Hradec Kralove.