Collaborative filtering is another technique that can be used for recommendation.
The underlying concept behind this technique is as follows: ◾Assume Person A likes Oranges, and Person B likes Oranges. ◾Assume Person A likes Apples. ◾Person B is likely to have similar opinions on Apples as A than some other random person.
The implications of collaborative filtering are obvious: you can predict and recommend items to users based on preference similarities. There are two types of collaborative filtering: user-based and item-based.
Item Based Collaborative Filtering takes the similarities between items’ consumption history. User Based Collaborative Filtering considers similarities between user consumption history.
We will look at both types of collaborative filtering using a publicly available dataset from Last.FM
Source : Salem Marafi