Reputation: 174
I'm trying to do recommendation based on feature similarity where my points in feature space represent unique classes. Essentially I have hundreds of unique items represented as low-dimensional feature vectors and I want to find the k-nearest neighbors in rank order for a new observation.
Conventionally you find the k neighbors and choose the class with the majority of representation therein. That won't work in my case considering each item has its own class.
Is kNN the wrong approach here? Is there a different family of algorithms more appropriate for this kind of problem?
Upvotes: -1
Views: 1183
Reputation: 6534
It sounds like you want to build a recommender system, where you recommend new products based on a product already purchased. This is not a classification problem, and so you shouldn't be treating it like one.
What method to use really depends on more details about your data, the amount, the feature representation, and other issues. Recommender systems are often a harder problem them simple classification with more nuanced issues. This coursera course may be more helpful to you.
Upvotes: 2
Reputation: 19179
Whether kNN is the right approach boils down to whether your classes are well characterized by a distance metric in your feature space. There is nothing inherently wrong with what you are proposing. You can simply associate a unique class with each training observation and then apply kNN with k = 1
.
Upvotes: 2