Says, a dataframe df_1
has 8 columns, and following code is used.
res = kmeans(df_1, 4, nstart=40)
The K-means clustering result is stored in res
.
In most examples, two dimensions (i.e. two columns) are used to demonstrate the clustering.
However, in the above code, df_1
has 8 dimensions.
How do I know, which columns were used?