## 4 Results  
The performance of the IDS was evaluated based on its ability to classify network traffic into a specific type. The paper presents the results of the testing process of the proposed algorithm, which was performed by the ensemble. We compared its performance by various metrics, such as accuracy, precision, detection rate (DR), F-measure, time (training and testing), and error rate. The first step in the PCA process was to identify the PCAs. The proposed PCA method can reduce the dimensionality of the dataset significantly. It also eliminates irrelevant features. An ensemble classifier was also employed to increase the performance of IDS. This method combines three classifiers in a voting algorithm: RF, KNN, and ET. As a result, four separate classifiers were built using the training and testing datasets for classification. Table 2 shows the best classification performance with and without the dimensionality reduction method regarding the primary metrics used. The number of PCAs in (b) part of Table 2 represents the principal components for each classifier. We repeatedly ran the experiment to evaluate the performance of the classifiers. Gradually, the number of PCAs/features was increased for each classifier. In each iteration, we \begin{table}
\begin{tabular}{c c c c c c c c c} \hline \hline \multicolumn{1}{c}{**Classifier**} & \multicolumn{1}{c}{**PCAs**} & \multicolumn{1}{c}{**Accuracy**} & \multicolumn{1}{c}{**Precision**} & \multicolumn{1}{c}{**DR**} & \multicolumn{1}{c}{**F-Measure**} & \multicolumn{1}{c}{**Training (s)**} & \multicolumn{1}{c}{**Testing (s)**} & \multicolumn{1}{c}{**Error Rate**} \\ \hline Ensemble & * & 0.996 & 0.999 & 0.999 & 0.999 & 36.22 & 3.9 & 0.004 \\ \hline RF & * & 0.997 & 0.999 & 0.999 & 0.999 & 5.493 & 0.613 & 0.003 \\ \hline KNN & * & 0.991 & 0.995 & 0.995 & 0.995 & 2157.8 & 231.024 & 0.003 \\ \hline ET & * & 0.997 & 0.998 & 0.998 & 0.998 & 0.113 & 0.014 & 0.003 \\ \hline PSOM [17] & * & 0.88 & 0.90 & 0.92 & - & - & - & - \\ \hline \multicolumn{1}{c}{**(b)**} & \multicolumn{1}{c}{**(b)**} & \multicolumn{1}{c}{**(c)**} & \multicolumn{1}{c}{**(d)**} & \multicolumn{1}{c}{**(e)**} & \multicolumn{1}{c}{**(f)**} & \multicolumn{1}{c}{**(f)**} \\ \hline
**Classifier** & **PCAs** & **Accuracy** & **Precision** & **DR** & \multicolumn{1}{c}{**F-Measure**} & \multicolumn{1}{c}{**Training (s)**} & \multicolumn{1}{c}{**Testing (s)**} & \multicolumn{1}{c}{**Error Rate**} \\ \hline Ensemble & 30 & 0.998 & 0.998 & 0.998 & 0.998 & 19.256 & 2.238 & 0.002 \\ \hline RF & 24 & 0.978 & 0.987 & 0.977 & 0.977 & 4.490 & 0.518 & 0.003 \\ \hline KNN & 24 & 0.926 & 0.966 & 0.986 & 0.976 & 14.280 & 1.600 & 0.004 \\ \hline ET & 15 & 0.954 & 0.944 & 0.984 & 0.984 & 0.061 & 0.007 & 0.006 \\ \hline PSOM+PCA [17] & 15 & 0.90 & 0.80 & 0.97 & - & - & - & - \\ \hline \hline \end{tabular}
\end{table} 
Table 2: (a) The performance outcomes according to original features. (b) The performance outcomes according to the chosen features using PCA. increased the number of PCAs until adding a new one did not improve the model's performance. As shown in Figure 2, the performance of the Ensemble models was not improved after 30 PCAs and 24, 24, and 15 PCAs for RF, KNN, and ET, respectively. The performance of the ensemble method obtained the maximum accuracy rate of 99.89% with 30 PCAs and exceeded all other individual classifiers. In contrast, the best accuracy of the RF, KNN, and ET classifiers were 97.85%, 92.65%, and 95.45% with 24, 24, and 15 PCAs, respectively. Moreover, the proposed model has the highest scores in DR, precision, and F-measure and the lowest error rate compared to other combined models, as shown in Table 2.  
As compared to other studies, the results obtained using the ensemble method are superior when compared with other studies.