I am working on Kmeans clustering algorithm. When I try to access the cluster labels it is showing:
numpy.ndarray object has no attribute labels_
My code is as follows:
movies=np.array(movies)
kmeans=KMeans(n_clusters=19).fit_predict(movies)
print(kmeans.labels_)
print dir(kmeans)to get a list of all the attributes available in thekmeansobject