## 5 Results  
The results in Figure 4 show the weighted average \(F1\)-_scores_ of six different prediction algorithms trained on three datasets. The results showed that the decision tree algorithms (including RF) were the most accurate and their results were quite similar to all datasets. The CART decision tree algorithm was the most accurate, achieving 99.22% of the weighted average \(F1\)-_score_ over the 3 datasets. However, this accuracy result was only \(\sim\)0.6% better than with RF or another decision tree model-ID3. The worst classification results were shown by the dense-layer net and LR models. In terms of datasets, the CSE-CIC-IDS-2018 dataset (88.81) gave the worst results and the CIC-IDC2017 dataset the best (91.48%). Meanwhile, the merged dataset achieved an average accuracy of 90.04%. To understand these performance results, the experimental results for each algorithm (including different accuracy metrics) are provided below. Table 3 shows classification results of six different ML models providing precision, recall and \(F1\)-_score_ values, including two performance metrics. Taking into account all 3 performance metrics, it was evident that the DT (CART)-based model demonstrated the highest level of accuracy, with \(F1\)-_score_ values ranging from 96.87% to 99.87%. \begin{table}
\begin{tabular}{l l l l l} \hline \hline \multicolumn{1}{c}{**Model**} & \multicolumn{1}{c}{**Performance Metrics**} & \multicolumn{1}{c}{_Precision_} & \multicolumn{1}{c}{_Recall_} & \multicolumn{1}{c}{_F1-Score_} \\ \hline LR & Accuracy & 0.83741 & 0.83741 & 0.83741 \\  & Weighted average & 0.72454 & 0.83741 & 0.77504 \\  & Macro average & 0.14042 & 0.14438  
The _F1-score_ accuracy results for each algorithm for each class of the dataset are presented below (see Figure 5). The figure shows that the LR model failed to detect such intrusion classes as \"Bot\", \"Heartbleed\", \"Infiltration\", \"PortScan\", \"SSH-Patator\" and \"FTP -Patator\". _F1-score_ values greater than 0 were obtained for such classes as \"Dos slowloris\" (0.18%), \"DoS Attack-slowloris\" (40.73%) and \"DDoS\" (54.25%), although these scores are not high. Higher values were obtained for only two classes--\"Benign\" (91.62%) and \"DDOS attack-LOIC-UDP\" (70.53%) (see Figure 5a). The DT-based algorithms achieved quite high scores, but the most accurate was the DT(CART) algorithm, which reached high _F1-score_ results (>90%) for the majority of classes (see Figure 5b). Only three attack classes had lower results: \"Infiltration\" (68.96%), \"SQL Injection\" (77.08%) and \"Web Attack Sql Injection\" (85.71%). The ID3 algorithm did not identify classes, such as \"Web Attack Sql Injection\", \"Heartbleed\" and \"SQL Injection\", but attacks, such as \"SSH-Bruteforce\", \"FTP-BruteForce\" and \"DoS attacks-SlowHTTPTest\", were identified with the highest accuracy >99.9% (see Figure 5c). Figure 5: Radar charts for comparing classification models in terms of _F1-score_ accuracy for all intrusion classes. **(a)** LR; **(b)** DT(CART); **(c)** DT (ID3); **(d)** RF; **(e)** MLP; **(f)** Dense-layer net. Concerning the results obtained from RF, the majority of classes were successfully classified with an accuracy rate exceeding 99%. Meanwhile, prediction success rates of \"Web Attack-Brute Force\", \"Web Attack-Sql Injection\" and \"Web Attack-XSS\" data classes were significantly lower, ranging from 33.3% to 77.3%. Among the different data classes, the RF algorithm achieved the lowest score for \"Infiltration\" attacks (13.45%) and the highest score (99.99%) for \"SSH-Patator\" attacks, as illustrated in Figure 5d. The classification results with MLP showed (Figure 5e) that the algorithm identified certain classes of attacks very well, i.e., \"SSH-Bruteforce\", \"FTP-Patator\" and \"Web Attack Sql Injection\", but did not identify others at all (the _F1-score_ value was 0.). The worst results were obtained with the dense-layer net model, which only classified the \"Benign\" class correctly with 90.81% accuracy.