我想使用 hierarchical cluster analysis 自动获得最佳数量(K)的簇,然后将此K应用于python中的 K-means clustering .

在研究了很多文章后,我知道一些方法告诉我们可以绘制图形来确定K,但是有任何方法可以在python中自动输出实数吗?