K-Nearest Neighbors Model to Optimize Data Classification According to the Water Quality Index of the Upper Basin of the City of Huarmey
Listed in
This article is not in any list yet, why not save it to one of your lists.Abstract
Water quality in the city of Huarmey-Lima-Peru is assessed through monitoring processes conducted by the National Water Authority (ANA). Traditional formula-based calculations and Excel macros, along with manual data validation, significantly extend the analysis and documentation time for evaluating water quality parameters. This study focuses on classifying water samples into Human Consumption (1-A2) and Animal Drinking (3-D2) categories by developing a machine learning model, specifically utilizing the K-Nearest Neighbors (KNN) algorithm. The primary objective is to enhance accuracy and efficiency in classifying water quality for human and animal consumption, aligning with Peru's Water Quality Index standards (WQI). The implementation of the KNN model demonstrated superior classification performance compared to traditional spreadsheet-based methods, achieving an accuracy of 75% with Excel-based classification and 90% using KNN. Additionally, the research evaluates the performance of KNN against Random Forest (RF) and Support Vector Machine (SVM). This approach significantly improved the speed and accuracy of water sample categorization, benefiting decision-making in water resource management for the Huarmey basin.