df_features=pd.read_csv(r'C:\预处理后数据.csv',encoding='gbk')# 读入数据'利用SSE选择k'SSE=[]# 存放每次结果的误差平方和forkinrange(1,9):estimator=KMeans(n_clusters=k)# 构造聚类器estimator.fit(df_features[['R','F','M']])SSE.append(estimator.inertia_)# estimator.inertia_获取聚类准...