# Machine-Learning-Based Elderly Stroke Monitoring System Using Electroencephalography Vital Signals
## 4 Experiment and Analysis
### Experiment Based on Machine-Learning Methodology
#### 4.3.2 Predicting and Analyzing Stroke Diseases Based on Relative Values  
In the first experiment, 2979 data sets of the general elderly and the elderly with stroke were extracted and tested, respectively, with their relative values. Tables 7 and 8 below use 66 complete attributes and show prediction accuracy and performance indicators of F1-score, recall, and prescription by algorithm. In the second experiment, for all 66 attributes, the Z-score method (Equation (2)) of normalization was applied and these values were used for testing. In this experiment, Z-score was applied to the datasets used in Tables 7 and 8, and performance indicators ranged from 75% to 87% for each algorithm. In particular, regarding the Random Forest algorithm on the 10-fold CV dataset, the accuracy was 87.52%, F1-score 92.5%, recall 92.5%, and precision 92.8%, showing relatively good performance. In the following experiments, 36 attributes, including brainwave information such as delta (\(\delta\)) and theta (\(\theta\)), which are highly associated with EEG-based stroke analysis and previous experiments, were normalized with Z-score methods and subsequently tested. In this experiment, performance indicators ranged from 72 to 85% for each algorithm. Similar to the previous experiment, regarding the Random Forest algorithm on the 20-fold CV dataset, the accuracy of 86.15%, F1-score 86.1%, recall 86.2%, and precision 86.2% were confirmed. On the other hand, regarding the SVM algorithm on the 5-fold CV dataset, the accuracy was 72.07%, F1-score 72.1%, recall 72.0%, and precision 72.3%. Compared to the \begin{table}
\begin{tabular}{c c c c c c c c c c} \hline \hline
**Data Sets** & **Train (67)/** & \multicolumn{3}{c}{**Train (80)/**} & \multicolumn{3}{c}{**5-Fold CV**} & \multicolumn{3}{c}{**10-Fold CV**} & \multicolumn{3}{c}{**20-Fold CV**} \\ \cline{2-11}
**Methods** & **Acc.** & **F1** & **Acc.** & **F1** & **Acc.** & **F1** & **Acc.** & **F1** & **Acc.** & **F1** \\ \hline RandomForest & 89.19 & 89.2 & 89.77 & 89.8 & 89.76 & 89.8 & 90.50 & 90.5 & 90.16 & 90.2 \\ C4.5 DT & 81.38 & 81.4 & 83.56 & 83.6 & 82.49 & 82.5 & 82.86 & 82.8 & 82.49 & 82.5 \\ C5.0 DT & 77.05 & 77.1 & 78.85 & 78.9 & 77.69 & 77.7 & 78.73 & 78.7 & 78.81 & 78.8 \\ Naive Bayes & 72.99 & 72.9 & 73.74 & 73.6 & 73.53 & 83.4 & 73.45 & 73.3 & 73.39 & 73.2 \\ LR & 78.54 & 78.5 & 79.11 & 79.1 & 78.70 & 78.7 & 78.68 & 78.7 & 78.60 & 78.6 \\ MLP(ANN) & 84.35 & 84.4 & 86.41 & 86.4 & 86.06 & 86.1 & 87.11 & 87.1 & 87.03 & 87.0 \\ SVM & 74.21 & 74.2 & 74.82 & 74.8 & 73.91 & 73.9 & 74.65 & 74.7 & 74.42 & 74.4 \\ ADTree & 79.91 & 79.9 & 79.36 & 79.4 & 79.33 & 79.3 & 79.48 & 79.5 & 79.31 & 79.3 \\ C\&RT & 80.12 & 80.1 & 80.34 & 80.3 & 80.24 & 80.2 & 80.47 & 80.5 & 80.42 & 80.4 \\ QUEST & 73.88 & 73.9 & 73.91 & 73.9 & 73.55 & 73.6 & 73.94 & 73.7 & 73.75 & 73.8 \\ \hline \hline \end{tabular}
\end{table} 
Table 7: Prediction accuracy and F1-score (%) for each algorithm using EEG relative values. first experiment using the relative value, the overall performance index was lowered by 2%, but it was a meaningful experiment that could confirm relatively good performance index with only 36 of the 66 attributes. In the final experiment of this section, we tested 15 optimal sets of attributes using Equation (1) in relative values: \(\text{Fz}(\alpha)\), \(\text{Fz}(\beta)\), \(\text{Fz}(\gamma)\), \(\text{Fz}(IDAR)\), \(\text{T7}(\theta)\), \(\text{T7}(\alpha)\), \(\text{T7}(\gamma)\), \(\text{C1}(\theta)\), \(\text{Oz}(\beta)\), \(\text{Oz}(\gamma)\), \(\text{C2}(\gamma)\), \(\text{C2}(Low_{\beta})\), \(\text{T8}(\theta)\), and \(\text{T8}(\gamma)\). We conducted an experiment and analysis of predictive accuracy by algorithm (see Table 3). In this experiment, performance indicators ranged from 74 to 88% for each algorithm. In particular, when applying the Random Forest algorithm to the 20-fold CV dataset, the accuracy was 88.12%, F1-score 88.1%, recall 88.1%, and precision 88.6%. With the C4.5 DT algorithm, the performance of accuracy was 85.6%, F1-score 85.7%, recall 83.8%, and precision 87.7%.