# Ensemble Method of Triple Naive Bayes for Plastic Type Prediction in Sorting System Automation
## 3 Results and Discussion
\begin{table}
\begin{tabular}{l c c c c} \hline \hline  & \begin{tabular}{c} **Predictor** \\ **Variable** \\ \end{tabular} & \multicolumn{3}{c}{\begin{tabular}{c} **Category** \\ **(m)** \\ \end{tabular} } \\ \cline{3-5}  & \begin{tabular}{c} \(X_{1}\) \\ **Variable** \\ \end{tabular} & \begin{tabular}{c} [0.329, 0.776] \\ **1** \\ \end{tabular} & \
\begin{tabular}{c} [0.553, 0.751, 0.944, 0.948] \\ **1** \\ \end{tabular} &
\begin{tabular}{c} [0.888, 1] \\ **2** \\ \end{tabular} \\ \hline \multirow{3}{*}{**Fuzzy**} & \(X_{1}\) & [0.329, 0.776] & [0.553, 0.751, 0.944, 0.948] & [0.888, 1] \\  & \(X_{2}\) & [0.350, 0.783] & [0.567, 0.711, 0.656, 0.946] & [0.892, 1] \\  & \(X_{3}\) & [0.330, 0.776] & [0.553, 0.651, 0.748, 0.944] & [0.888, 1] \\ \cline{1-1}  & \(X_{4}\) & [0, 0.667] & [0.333, 0.479, 0.625, 0.916] & [0.833, 1] \\ \cline{1-1}  & \(X_{5}\) & [0, 0.082] & [0.039, 0.167, 0.295, 0.552] & [0.104, 1] \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Linear–trapezoidal fuzzy discretization. \begin{table}
\begin{tabular}{l c c c c} \hline \hline  & \begin{tabular}{c} **Predictor** \\ **Variable** \\ \end{tabular} & \multicolumn{3}{c}{\begin{tabular}{c} **Category** \\ **(m)** \\ \end{tabular} } \\ \cline{3-5}  & \begin{tabular}{c} \(X_{1}\) \\ **Fuzzy** \\ \end{tabular} & \begin{tabular}{c} [0.329, 0.776] \\ **1** \\ \end{tabular} & \
\begin{tabular}{c} [0.553, 0.948, 0.944] \\ **1** \\ \end{tabular} &
\begin{tabular}{c} [0.888, 1] \\ **2** \\ \end{tabular} \\ \hline \multirow{3}{*}{**Fuzzy**} & \(X_{2}\) & [0.350, 0.783] & [0.567, 0.656, 0.946] & [0.892, 1] \\  & \(X_{3}\) & [0.330, 0.776] & [0.553, 0.748, 0.944] & [0.888, 1] \\ \cline{1-1}  & \(X_{4}\) & [0, 0.667] & [0.333, 0.625, 0.916] & [0.833, 1] \\ \cline{1-1}  & \(X_{5}\) & [0, 0.082] & [0.039, 0.295, 0.552] & [0.104, 1] \\ \hline \hline \end{tabular}
\end{table} 
Table 3: Linear–triangular fuzzy discretization. Among the three basic models, the highest model performance in the first sampling of 5-fold cross-validation is owned by the NB model with crisp discretization, while the lowest is owned by the NB model with linear-trapezoidal discretization. The ensemble of the triple NB model exhibits the highest performance compared to the other three basic models in accuracy, precision, and recall, with a percentage of 97.78-98.04%. Furthermore, the performance of these models cannot be generalized, considering that each sampling can provide different prediction performance as presented in Figure 6. The figure shows that the four proposed models have different performances in each random resampling of 5-fold cross-validation technique. The twenty-seventh resampling \begin{table}
\begin{tabular}{c c c c c} \hline \hline \multirow{2}{*}{**Model**} & \multicolumn{4}{c}{**Performance Metric**} \\ \cline{2-5}  & \multicolumn{1}{c}{**Accuracy**} & \multicolumn{1}{c}{**Precision**} & \multicolumn{1}{c}{**Recall**} \\ \hline NB with crisp discretization & 95.56 & 95.54 & 96.08 \\ NB with linear–triangular fuzzy discretization & 94.44 & 95.06 & 94.19 \\ NB with linear–trapezoidal fuzzy discretization & 93.33 & 94.21 & 92.91 \\ Ensemble of triple NB & 97.78 & 97.92 & 98.04 \\ \hline \hline \end{tabular}
\end{table} 
Table 6: Performance metrics on the first resampling for single and ensemble model.