Research Article
Novel Automated K-means++ Algorithm for Financial Data Sets
| Input: k, dataset | | Output: center, texts | | function CLUSTERING | | center = null | | texts = null | | m = the number of data objects in the dataset | | max = 0 | | for do | | if then | | temp = maximum density(m) | | center[i] = dataset[temp] | | else | | for do | | for do | | distance[j][h] = cosine distance of the dataset[j] and center[h] | | end for | | end for | | for do | | for do | | Sum_distance[j] + = distcance[j][h] | | end for | | end for | | for do | | if Sum_distance[j] max then cluster[i] = dataset[j] | | end if | | end for | | 2–4. Proceed as with the standard K-means algorthm | | end if | | end for | | return center, texts | | end function |
|