The Mahout In Action (Chapter 6) book contains a recommendation method based on matrix multiplication that uses co-occurrence data (C) in combination with user preferences (U) to generate user recommendations (R).
Here's a small example to illustrate it. Say the co-occurrence matrix for 4 items is
C = [5 3 4 4 2 1 0 3 2 2 1 6 1 4 1 5]
and the user preference vector is
U = [2 3 0 0]
Here, we know the user's relative level of interest in the first two items and we are trying to gauge which one of the other two items can be used as a recommendation.
To find this, we first fill in 0s for those items and then perform a simple matrix multiplication and compute R = C * U
R = [19 7 10 14]
With this information, we ignore the first two terms (because we already know the level of the user's interest in them) and conclude that item #4 is a better recommendation compared to item #3.
Question:
Is there a "formal" name for this method or is this just a variant of collaborative filtering? Is there a mathematical basis (and/or intuition) for why such a method should work?
Compared to other recommendation methods (such as matrix factorization for instance), this approach is very simple because it only requires simple matrix multiplication. I'm wondering if there has been a study to compare such a simple method to the more complex ones.
Best Answer
Considering your request as well as the fact that your question fits the context of recommender systems, I think that you may benefit from reviewing some information on matrix factorization techniques (including NNMF – non-negative matrix factorization) for producing recommendations. I hope that the following resources will be useful for you in this regard as a starting point:
- Matrix factorization techniques for recommender systems: http://www2.research.att.com/~volinsky/papers/ieeecomputer.pdf
- Matrix factorization: A simple tutorial and implementation in Python: http://www.quuxlabs.com/blog/2010/09/matrix-factorization-a-simple-tutorial-and-implementation-in-python
- NNMF and recommender systems (simplified R version of the previous item): http://econometricsense.blogspot.com/2012/10/nonnegative-matrix-factorization-and.html
Speaking of tools, specifically focused on Non-Negative Matrix Factorization (NMF) or supporting this technique, the following resources might be of your interest:
- One of such tools is Python Matrix Factorization (PyMF) library with home page at https://code.google.com/p/pymf and source code at https://github.com/nils-werner/pymf.
- Another, even more interesting, library, also Python-based, is NIMFA, which implements various NMF algorithms: http://nimfa.biolab.si. Here's a research paper, describing
NIMFA
: http://jmlr.org/papers/volume13/zitnik12a/zitnik12a.pdf. - Finally, CMU's GraphLab machine learning library looks very promising, containing, among other components, a collaborative filtering library, which supports NNMF and other algorithms (scalable via MapReduce & multicore): http://select.cs.cmu.edu/code/graphlab/pmf.html.
Similar Posts:
- Solved – Matrix Factorization Model for recommender systems how to determine number of latent features
- Solved – Matrix Factorization Model for recommender systems how to determine number of latent features
- Solved – Recommendation systems as learning to rank problem
- Solved – Recommendation systems as learning to rank problem
- Solved – Interpretation of matrix factorization results