Session Ready
Exercise

Making recommendations with TF-IDF

In the last exercise you pre-calculated the similarity ratings between all movies in the dataset based on their plots transformed by TF-IDF. Now you will put these similarity ratings in a DataFrame for ease of use. Then you will use this new DataFrame to suggest a movie recommendation.

The cosine_similarity_array containing a matrix of the similarity values between all movies that you created in the last exercise has been loaded for you. The tfidf_summary_df DataFrame containing the movies and their TF-IDF features is also available.

Instructions 1/2
undefined XP
  • 1
  • 2
  • Generate a DataFrame from cosine_similarity_array.
  • Store the cosine similarity values between the movie Rio and all other movies as a Series.
  • Sort these from largest to smallest in ordered_similarities and print the ordered results.