ISPU-Based Air Quality Classification: A Comparison of KNN and Naive Bayes using SMOTE
Kata Kunci:
Air Quality, Class Imbalance, ISPU, K-Nearest Neighbors, Naive Bayes, SMOTEAbstrak
Automated air quality monitoring using machine learning is essential in urban environmental management. The main challenge in modeling atmospheric sensor data is the class imbalance phenomenon, where normal observation conditions overwhelmingly dominate extreme pollution events, causing inductive bias in the algorithms. This study compares the performance of K-Nearest Neighbors (KNN) and Gaussian Naive Bayes (GNB) in classifying air quality levels based on the Standard Air Pollutant Index (ISPU). To preserve the authenticity of time-series observations, data with missing values were removed using listwise deletion without imputation. The distributional imbalance was addressed through the Synthetic Minority Over-sampling Technique (SMOTE), implemented exclusively on the training data. The Confusion Matrix evaluation results indicate that GNB outperforms KNN with an accuracy of 86.00% compared to 83.00%. Comparative analysis proves that GNB is more robust to local noise and class overlap generated by SMOTE’s synthetic data, as GNB relies on statistically strengthening the global probability distribution curve. Conversely, the spatial distance calculation in KNN is susceptible to distortion by the density of synthetic instances in the decision boundary area. The GNB model is recommended as a more stable approach for operational ISPU classification.Referensi
M. Karmoude et al., “Machine learning for air quality prediction and data analysis: A comprehensive systematic review,” Science of The Total Environment, vol. 1002, p. 180593, 2025.
K. Tursun et al., “Dominant sources of PM2.5 in Kazakhstan’s urban cities: A PMF and HYSPLIT-based study for air quality management in Central Asia,” Urban Climate, vol. 64, p. 102706, 2025.
S. A. C. Franco, M. A. Correa, G. D. Aguiar, L. M. Gómez, and H. A.Colorado, “Characterization and source apportionment of ion and metals in PM10 in an urbanized valley in the American tropics using principal component analysis and positive matrix factorization,” Engineered Science, vol. 30, p.1154, 2024.
R. E. Rojano, H. A. Arregocés, and G. Restrepo, “Interannual variations in PM10 and PM2.5 due to wildfires in four air quality monitoring networks in the Colombian caribbean,” Environmental Challenges, vol. 21, p. 101360, 2025.
J. Gao, M. Lang,and Y. Jiang, “Assessing air quality improvements during the 2022 Beijing Winter Olympics: A case for sustainable urban management,” Cleaner Production Letters, vol. 9, p. 100116, 2025.
G. Palma and F. Scotti, “The effect of territorial servitization on air quality: Empirical analysis of PM2.5 concentration in Italian municipalities,” Journal of Cleaner Production, vol. 536, p. 147157, 2025.
H. P. Oswin et al., “Using indoor CO2 concentration thresholds to understand and improve the air quality of public buildings: A practical approach,” Energy & Buildings, vol. 347, p.116254, 2025.
S. Soomro et al., “Air quality management from the lens of leveraging social media data and machine learning algorithm for hazard zoning-real-time air pollution detection in urban cities under changing climate,” Journal of Environmental Management, vol. 396, p. 128110, 2025.
T. Dangare, N. R. Matandirotya, E. Matandirotya, and G. Mahed,”Leveraging low-cost sensors and machine learning for air quality monitoring and AQI prediction in resource-constrained environments,” Scientific African, vol. 30, p. e02992, 2025.
N. Deepa, J. S. Priya, and T. Devi, “Towards applying internet of things and machine learning for the risk prediction of COVID-19 in pandemic situation using Naive Bayes classifier for improving accuracy,” Materials Today: Proceedings, vol. 62, pp. 4795–4799, 2022.
C. Mondal and M. J. Uddin, “Classification of short-term flood events using stochastic environmental variables and Gaussian Naive Bayes classifier,” Heliyon, vol. 11, no. 2, p. e41941,2025.
M. Ali, “Classification of imbalanced travel mode choice dataset with synthetic minority oversampling technique (SMOTE) and machine learning models,” Sustainable Futures,vol. 10, p. 101119, 2025.
S. Matharaarachchi, M. Domaratzki, and S.Muthukumarana, “Enhancing SMOTE for imbalanced data with abnormal minority instances,” Machine Learning with Applications, vol. 18, p. 100597, 2024.
N. V. Chawla, K. W. Bowyer,L. O. Hall, and W. P. Kegelmeyer, “SMOTE: Synthetic minority over-sampling technique,” Journal of Artificial Intelligence Research, vol. 16, pp. 321–357, 2002.
L. C. M. Liaw, S. C. Tan, P. Y.Goh, and C. P. Lim, “A histogram SMOTE-based sampling algorithm with incremental learning for imbalanced data classification,” Information Sciences, vol. 686, p. 121193, 2025.
E. N. Amachaghi, S. A. Abdulkareem, C. H. Foh,D. Mi, and M. Shojafar, “Improving intrusion detection in O-RAN with synthetic data generation: A GAN and SMOTE approach,” Telematics and Informatics Reports, vol. 20, p. 100269, 2025.
H. Hafiz, D. Li, P. Luo, A. R. Rasa, and B. Yang, “Interpretable k-nearest neighbors for rockburst risk prediction: Robust performance and mechanistic insights for deep rock engineering,” Engineering Failure Analysis, vol. 186, p. 110443, 2026.
J. A. Qadir, “Enhancing Parkinson’s disease detection by combining SMOTE and feature selection for improved machine learning classification using voice recordings,” Journal of Voice, In Press, 2025.
H. I.Abdalla and A. A. Amer, “Enhancing data classification using locally informed weighted k-nearest neighbor algorithm,” Expert Systems with Applications, vol. 276, p. 126942, 2025.
A. Verdi, “KURVE: A web-based tool for estimating soil water retention and hydraulic conductivity curves using a k-nearest neighbor approach,” Journal of Hydrology, vol. 679, p. 136140, 2026.
Y. Algoufily, F. Borghesan, D. Vanhoutte, and M. Mercangöz, “A k-nearest neighbours framework with Trajectory-Embedded Decay for cycle-time forecasting in temperature swing adsorption,” Digital Chemical Engineering, vol. 20, p. 100323, 2026.
B. G. B. Bueno, M. Dahleh, and A. Hosoi, “A k-nearest-neighbors based method for estimation of treatment effects in agriculture without treatment labels,” Information Processing in Agriculture, In Press, 2026.
Y. Zeng, H. Wang,and X. Zhou, “K-nearest neighbor-enhanced Residual Learning Framework for image restoration,” Engineering Applications of Artificial Intelligence, vol. 167, p. 113816, 2026.
A. M. Corpuz, M. Jaiswal, M.-C. Hsu, and A.Krishnamurthy, “Multi-level k-nearest neighbors algorithm for direct point cloud-based engineering analysis,” Computer Methods in Applied Mechanics and Engineering, vol. 456, p. 118933, 2026.
S. Flesca, D. Mandaglio, and F. Scala, “Enhancing active learning through latent space exploration: A k-nearest neighbors approach,” Array, vol. 28, p. 100584, 2025.
H. Zhang et al., “A scalable and semi-supervised approach for Ethereum fraud detection using Graph Neural Networks and K-Nearest Neighbors clustering,” Journal of Information Security and Applications, vol. 95, p. 104255, 2025.
M. Kuronen, J.Räty, P. Packalen, and M. Myllymäki, “Uncertainty quantification for forest attribute maps with conformal prediction and k-nearest neighbor method,” Remote Sensing of Environment, vol. 325, p. 114758, 2025.
Y. Manza, R. Rosnelly, M. Furqan, and B. S. Riza, “Optimized KNN performance with PCA and K-fold cross-validation for colorectal cancer survival prediction,” Jurnal Teknik Informatika (Jutif), vol. 7, no. 1, pp. 361–372, 2026.
M. R. Wayahdi and F. Ruziq, “Predicting smartphone addiction levels with K-nearest neighbors using user behavior patterns,” Jurnal Teknik Informatika (Jutif), vol. 6, no. 5, pp. 3379–3391, 2025.
F. Ruziq and M. R. Wayahdi, “Web-based diabetes risk prediction system using K-NN on Kaggle early stage diabetes dataset,” Jurnal Teknik Informatika (Jutif), vol. 6, no. 5, pp. 3217–3229, 2025.
X. Chen, Z. Yuan,and S. Feng, “Anomaly detection based on improved k-nearest neighbor rough sets,” International Journal of Approximate Reasoning, vol. 176, p. 109323, 2025.
O. Peretz, M.Koren, and O. Koren, “Naive Bayes classifier – An ensemble procedure for recall and precision enrichment,” Engineering Applications of Artificial Intelligence, vol. 136, p. 108972, 2024.
S. Raj, A. Vishnoi, and A. Srivastava, “Classify Alzheimer genes association using Naïve Bayes algorithm based on biomedical text mining,” Human Gene, vol. 41, p. 201309, 2024.
A. V. D. Sano et al., “Proposing a visualized comparative review analysis model on tourism domain using Naïve Bayes classifier,” Procedia Computer Science, vol. 227, pp. 482–489, 2023.
M. R. Wayahdi, F. Ruziq, A. Nasution, and E. Purwawijaya, “Predictive modeling of smartphone addiction: performance evaluation of KNN, XGBoost, and Naive Bayes on behavioral patterns,” Jurnal Minfo Polgan, vol. 15, no. 1, pp. 467–477, 2026.
N. Nurhayati, L. Hartimar, Y. Manza, and K. P. Siregar, “Text classification using TF-IDF and Naïve Bayes: case study of MyXL app user review data,” Journal of Technology and Computer, vol. 2, no. 2, pp. 100–108, 2025.
Unduhan
Diterbitkan
Terbitan
Bagian
Lisensi
Hak Cipta (c) 2026 Journal of Technology and Computer

Artikel ini berlisensi Creative Commons Attribution 4.0 International License.











