Recommendation Systems and learn how to build a Movie Recommendation System using collaborative filtering by implementing the K-Nearest Neighbors algorithm.
collaborative filtering method is usually based on collecting and analyzing information on user’s behaviors, their activities or preferences, and predicting what they will like based on the similarity with other users.
I am using the MovieLens dataset from https://grouplens.org/datasets/movielens/latest/. The data consists of 105339 ratings applied over 10329 movies. There are two data file:
- The details.data dataset contains four columns: 'user_id', 'item_id', 'rating', 'timestamp'.
- The Movie_Id_Titles dataset contains two columns: 'item_id' and 'title'.
A. Deleting Unnecessary Columns
B. Data Cleaning
C. We meerge them together on item_id
D. Remove the NaN values from the dataset .Combining the files and making a pivot table
E. We used Cosine Similarity for finding the similarity between 2 movies.
F. We used K-Nearest Neighbors (e.g. K=6) find 6 most similar movies. These 6 movies will help in predicting for our desired movie.
A. KNN (K- Nearest Neighbor) B. Cosine Similarity C. Popularity (most rated) based recommender
https://www.analyticsvidhya.com/blog/2020/08/recommendation-system-k-nearest-neighbors/