Abstract
As digital governance progresses rapidly, constructing digital portraits of residents has become instrumental in enhancing local-level administrative capabilities. Nonetheless, traditional K-means clustering algorithms struggle with the classification of high-dimensional and complex data, thereby limiting their effectiveness. To address this issue, this paper proposes a novel hybrid algorithm-PSO-KM-that integrates Particle Swarm Optimization with K-means to improve both accuracy and computational efficiency in clustering resident profile data. Drawing on comprehensive resident information collected in 2023 from a community management system, the method leverages PSO's global optimization abilities alongside K-means' iterative refinement to dynamically update cluster centroids. Performance evaluation shows a significant uplift in clustering metrics, with a silhouette score of 0.752 ± 0.021 and inter-cluster distance of 1.493 ± 0.036. Comparative analysis against conventional and advanced methods (e.g., GA-K-means, DBSCAN) reveals that PSO-KM delivers superior outcomes. Among different feature categories, behavioral data yield the best classification performance, with a silhouette value of 0.184, highlighting the discriminatory power of dynamic behavioral traits. Furthermore, segmentation results disclose varying dominant features across income brackets: demographic factors are primary for low-income groups, behavioral metrics dominate middle-income segments, while social network indicators are key for high-income populations. These insights confirm PSO-KM's potential in refining digital profiling processes and fostering the advancement of grassroots digital governance practices.