Professional Documents
Culture Documents
Chapter4 - Web Based Personalization Systems - Part2 - Collaborative Filtering - KNN
Chapter4 - Web Based Personalization Systems - Part2 - Collaborative Filtering - KNN
CF – Limitations
Collaborative RS
Introduction
Key is to find users/user groups whose interests
match with the current user
More users, more ratings: better results
Collaborative RS
User-based collaborative filtering
Item-based collaborative filtering
Collaborative RS...
• Recommendation task 1:
– Predicting the rating on a target item for a given user
– Predicting John’s rating on Star Wars Movie
movie1 ??
Recommender
• Recommendation task 2:
– Recommending a list of items to a given user
– Recommending a list of movies to John for watching
List of Top
Movies ??
Recommender
Collaborative RS...
Collaborative filtering (CF) is perhaps the most studied
and also the most widely-used recommendation
approach in practice.
K-nearest neighbor (KNN)
User-based KNN CF
Item-based KNN CF
Association Rules
Item-based KNN CF
Collaborative RS Using KNN
1. User Based KNN CF
A user-based KNN collaborative filtering method consists of
two primary phases:
the neighborhood formation phase
sim x,𝑦
Collaborative RS Using KNN...
1. User Based KNN CF
ii. Recommendation Phase
Use the following formula to compute the rating prediction of item i for
target user x
sim x,𝑦 × 𝑟y,i − 𝑟
𝑝 u,i = 𝑟𝑥 +
sim x,𝑦
where x is the set of k similar users,
ry,i is the rating of user y given to item i,
Collaborative RS Using KNN
Example: Using Pearson Correlation
Consider Alice and all the other users ratings of news media in the table
below. Predict the ratings of Alice to I5(BBC) based user based similarity
using Pearson correlation.
Step 1: Calculating the similarity between Alice and all the other users
At first we calculate the averages of the ratings of all the user excluding I5 as it is
not rated by Alice. Therefore, we calculate the average as ,
Collaborative RS Using KNN…
Hence, with the help of a small example we tried to understand the working of
User-based collaborative filtering.
Step 2: Generating the missing ratings in the table. Now, in this step we
calculate the ratings that are missing in the table.
Collaborative RS
Collaborative RS - Limitations
Finding similar users/user groups isn’t very easy
New user: No preferences available (user cold start problem)
New item: No ratings available (item cold start problem)
Sparsity of rating matrix as dimension grows