## 5 Results
Most intrusion attack classes had a classification accuracy of 0% value, and only a few had an accuracy in the range of 10-20% (\"DDoS\" type attacks). As the dataset was heavily imbalanced, it was important to verify how accuracy correlated with sample size. The testing sample size for each of the classes is given in Figure 6.  
Support value dependencies on _F1-score_ accuracy are provided in Figure 7. As the difference in support values was very significant, it was appropriate to consider a logarithmic scale for the support values. Near-linear dependencies were observed in the DT CART and ID3 models. However, the DT ID3 and RF models had more outliers. For example, the \"Infiltration\" class with a high support value only achieved 13.45% of _F1-scores_ for the RF model and 11.09% for the DT ID3 model (see Figure 7c,d). Despite the low overall accuracy of the MLP model, the results presented in Figure 7e show that higher _F1-scores_ were only obtained at higher values of support. Figure 8 shows misclassification results for all six models, where it was important to evaluate the misclassification of malicious attacks as benign because this can lead to potential security risks and threats going undetected. Identifying and correctly classifying malicious attacks is important, but confusing certain malicious classes may be less critical than classifying them as benign. Figure 8 shows only malicious attacks, which are shown in red if the attack was correctly classified, in green if it was identified as benign and in gray if it was classified as malicious but the attack class was incorrectly assigned. The percentage values represented all of these cases for each attack class. Figure 6: Average support values (number of testing samples) for testing. The lowest class confusion was observed for the DT CART model (see Figure 8c). Those attack classes with higher confusion had a very low number of samples, i.e., the number of samples used for testing ranged from 7 instances (\"Web Attack Sql Injection\") to 100 (\"Brute Force-XSS\"). \"Infiltration\" attacks showed the most confusion, with 6 out of 17 attacks classified as \"Benign\" (green color) and 1 as another type (incorrect) of malware attack (gray color). Comparing the DT ID3 algorithm and RF, we can see that the results were more satisfactory with RF because they classified less malicious attacks as benign. The worst situation was for \"Infilteration\" type attacks, as most of them were classified as benign (almost 90%) (see Figure 8d). The situation with regard to the classification of \"Infilteration\" attacks was the same as for the DT ID3 model (Figure 8b). In addition, more than 60% of the sample for the other seven types of attacks were also classified as benign. For the LR model (Figure 8a), we can see that the majority of malicious attacks were classified as benign (\"Bot\", \"Brute Force-Web\", \"Hearttbleed\" \"DoS GoldenEye\", etc.). The most inappropriate model was the dense-layer net, which classified almost all malicious attacks as benign. The MLP model identifyied at least seven types of malicious attacks with high accuracy, but the rest were classified as benign attacks (see Figure 8e). Figure 7: Support value (Logarithm value) dependencies on _F1-score_, including the linear dependency line. (**a**) LR; (**b**) DT CART; (**c**) DT ID3; (**d**) RF; (**e**) MLP; (**f**) Dense-layer net.