## 3 Methodology
### iForest Outlier Detection
### Impact of Outlier Detection and Data Balancing Method

In this study, we examined the effect of iForest outlier detection and SMOTE on the accuracy of classification models. We found that the implementation of these techniques slightly improved the accuracy of the models. After removing noisy or outlier data and balancing the training set, the average accuracy of the classification models increased by about 0.13% compared to conventional machine learning models. Figure 5 shows the detailed impact of outlier detection and oversampling on classification accuracy. In our dataset, removing outliers and increasing the distribution of minority cases generally improved classification model accuracy, except for logistic regression. In conclusion, integrating iForest-based outlier detection and SMOTE for balancing the dataset into classification models can improve model accuracy. \begin{table}
\begin{tabular}{c c c c c c} \hline \hline \multirow{2}{*}{**Method**} & \multicolumn{5}{c}{**Performance Evaluation (\%)**} \\ \cline{2-6}  & **Accuracy** & **Precision** & **Specificity** & **Recall** & **F-Score** \\ \hline MLP & 71.165 \(\pm\) 5.745 & 70.001 \(\pm\) 7.665 & 92.923 \(\pm\) 1.388 & 67.699 \(\pm\) 6.106 & 65.728 \(\pm\) 6.537 \\ LR & 63.301 \(\pm\) 3.998 & 60.646 \(\pm\) 4.426 & 90.711 \(\pm\) 0.959 & 58.978 \(\pm\) 4.241 & 58.402 \(\pm\) 4.106 \\ KNN & 66.699 \(\pm\) 3.336 & 64.346 \(\pm\) 3.521 & 91.844 \(\pm\) 0.827 & 62.355 \(\pm\) 3.368 & 62.316 \(\pm\) 2.960 \\ DT & 86.699 \(\pm\) 4.343 & 86.477 \(\pm\) 3.881 & 96.713 \(\pm\) 1.075 & 85.570 \(\pm\) 3.887 & 85.519 \(\pm\) 4.084 \\ NB & 81.262 \(\pm\) 3.475 & 80.395 \(\pm\) 7.628 & 95.200 \(\pm\) 0.914 & 79.022 \(\pm\) 4.134 & 78.467 \(\pm\) 5.869 \\ XGBoost & 93.592 \(\pm\) 2.983 & 93.363 \(\pm\) 3.028 & 98.434 \(\pm\) 0.730 & 92.900 \(\pm\) 3.207 & 92.726 \(\pm\) 3.322 \\ AdaBoost & 93.107 \(\pm\) 3.174 & 92.963 \(\pm\) 3.161 & 98.312 \(\pm\) 0.772 & 92.624 \(\pm\) 3.139 & 92.418 \(\pm\) 3.289 \\ RF + iForest + SMOTE & 94.251 \(\pm\) 3.267 & 93.751 \(\pm\) 3.547 & 98.612 \(\pm\) 0.786 & 93.502 \(\pm\) 3.510 & 93.332 \(\pm\) 3.617 \\ \hline \hline \end{tabular}
\end{table} 
Table 3: Performance evaluation results. Figure 5: Impact of iForest and SMOTE on model prediction accuracy. ### Comparison with Previous Studies

In this study, we compared our study with previous studies related to the prediction model for detecting the movement and direction of RFID tags. Table 4 presents a comparison of the findings between our study and earlier research. [PERSON] et al. [10] applied Information Gain to find possible split points for moved and static tags. By utilizing RSS and timestamps as features, the proposed model could achieve an accuracy of up to 95.69%. [PERSON] et al. [11] utilized two readers to detect the movement of tags. The SVM model was utilized as a classifier to detect the moving tags. [PERSON] et al. [13] proposed false positive detection based on RF and Inter Quartile Range (IQR) outlier detection. The integrated model successfully detects moving tags up to 97.496. In addition, a recent study considered not only tag movement but also tag direction [17]. The statistical features were extracted from the RSS and timestamps, while XGBoost was utilized as a classifier. Our study utilized a dataset from [17] and showed improvement in prediction accuracy. We proposed a prediction model based on RF with iForest outlier detection and SMOTE data balancing. Furthermore, our study offered practical application by developing a web-based monitoring system. By embedding a trained prediction model into a web-based system, the direction of the tagged product can be presented easily to management. Table 4 should not be considered as strong evidence regarding model performance, but it provides a general comparison and allows discussions regarding the proposed model and previous approaches.