{'fraction_non_alphanumeric': 0.022909507445589918, 'fraction_numerical': 0.0, 'mean_word_length': 4.865771812080537, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Extended K-Means Algorithm

In the conventional K-means algorithm, the input data are automatically grouped into corresponding cluster by minimizing the within-cluster sum of squares. However, the traditional K-means algorithm doesn't do any constraints to the number of elements in each group. In the area of logistics management, each cluster will need to satisfy with a predefined number of elements. Thus, the clustering algorithm with controlled number of elements in each group is necessary. In this paper, we present a new method called extended k-means algorithm to extend the ordinary K-means approach. In this approach, the number of element in each group is adjusted by using greedy algorithm and the experimental results show that this extended K-means algorithm can work well for grouping data where the numbers of elements in each group need to be restrained.