I have a dataset of 17 features and class label for each datapoint. The description of dataset is as follows:

  • 2 features contain values 0, 1, 2, 3
  • 15 features contain values 0, 1, 2
  • class label containing value 0 or 1

I am given a set of clustering algorithms namely KNN, DBSCAN, Agglomerative clustering, Self Organizing Maps(SOM) and asked to implement each of these algorithm for the above dataset. I implemented them and plotted the obtained clusters with respective any of the two features on a scatter plot. Then I realized that there is no use doing clustering because either all of the points are considered a single cluster or each datapoint is considered a separate cluster.

I also tried one-hot encoding and then perform clustering, still the same result

Is there any use applying clustering algorithms on such data or am I doing something wrong in the implementation part here

Any help is appreciated

  • $\begingroup$ first thing to check: take a well-known dataset (e.g. Iris) and apply your algorithm implementations on. Do you get good result? $\endgroup$
    – lpounng
    Commented Apr 17, 2023 at 1:20
  • $\begingroup$ @Ipounng Yes, I applied all the algorithms for Iris dataset and results were good, maybe because it was a continuous dataset. I am trying to understand the results obtained for the discrete value dataset. $\endgroup$
    – foobar
    Commented Apr 17, 2023 at 9:26


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.