words = ['apple', 'Doppler', 'applaud', 'append', 'barker', 'baker',
    'bismark', 'park', 'stake', 'steak', 'teak', 'sleek']
dist = [distance.edit_distance(words[i], words[j]) for i in range(1, len(
    words)) for j in range(0, i)]
labels, error, nfound = PC.kmedoids(dist, nclusters=3)
cluster = dict()
for word, label in zip(words, labels):
    cluster.setdefault(label, []).append(word)
for label, grp in list(cluster.items()):
    pass
Can I use K-means algorithm on a string?