Clustering is an unsupervised learning technique used to group data based on the degree of similarity among object characteristics. This study aims to analyze the application of a distance formula in cluster formation using the K-Means algorithm on the Water Quality Dataset. The dataset consists of 7,999 observations and 20 columns representing various water quality characteristics. The target column, is_safe, was removed, resulting in 19 features used in the clustering process. The preprocessing stages included checking for duplicate data, handling missing values, converting data into numerical format, and applying Min-Max normalization within the range of [0,1]. Normalization was performed to standardize the scale across features, ensuring that each feature contributed proportionally to the distance calculation. The clustering process was conducted using the K-Means algorithm, with data proximity determined based on the distance formula. The results indicate that data preprocessing and the selection of an appropriate distance formula are important factors in determining proximity patterns among objects and the resulting cluster formation. The use of normalized data can reduce the dominance of features with larger value ranges, thereby enabling the clustering process to represent data characteristics more proportionally. This study demonstrates that distance formula analysis plays an important role in supporting the formation of representative clusters in water quality data.
Copyrights © 2026