Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

Duke University

Java Programming: Build a Recommendation System

Duke University via Coursera


Ever wonder how Netflix decides what movies to recommend for you? Or how Amazon recommends books? We can get a feel for how it works by building a simplified recommender of our own!

In this capstone, you will show off your problem solving and Java programming skills by creating recommender systems. You will work with data for movies, including ratings, but the principles involved can easily be adapted to books, restaurants, and more. You will write a program to answer questions about the data, including which items should be recommended to a user based on their ratings of several movies. Given input files on users ratings and movie titles, you will be able to:

1. Read in and parse data into lists and maps;
2. Calculate average ratings;
3. Calculate how similar a given rater is to another user based on ratings; and
4. Recommend movies to a given user based on ratings.
5. Display recommended movies for a given user on a webpage.


  • Introducing the Recommender
    • You will start out the capstone project by taking a look at the features of a recommender engine. Then you will choose how to read in and organize user, ratings, and movie data in your program. The programming exercise will provide a check on your progress before moving on to the next step.
  • Simple Recommendations
    • Your second step in building a recommender will focus on making simple recommendations based on the average ratings that a movie receives. You'll also make sure that each recommended movie has a least a minimal number of user ratings before including it in your recommendations. Throughout this step you are encouraged you use your knowledge of the seven step process to design useful algorithms and successful programs to solve the challenges you will face.
  • Interfaces, Filters, Database
    • In your third step, you will be encouraged to use interfaces to rewrite your existing code, making it more flexible and more efficient. You will also add filters to select a desired subset of movies that you want to recommend, such as 'all movies under two hours long' or 'all movies made in 2012'. You'll also make your recommendation engine more efficient as you practice software design principles such as refactoring.
  • Weighted Averages
    • In your fourth step, you will complete your recommendation engine by finding users in the database that have similar ratings and weighting their input to provide a more personal recommendation for the users of your program. Once you complete this step, you could request ratings of movies from those you know, run your program, and give them recommendations tailored to their own interests and tastes!
  • Farewell
    • Congratulations on completing your recommender programming project! As we conclude this capstone course, our instructors have a few parting words as you embark in future learning and work in computer science!

Taught by

Robert Duvall, Owen Astrachan, Susan H. Rodger and Andrew D. Hilton


4.7 rating at Coursera based on 633 ratings

Start your review of Java Programming: Build a Recommendation System

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.