%md # Movie recommendation with Spark ALS
xxxxxxxxxx
%md ## In this notebook, we will find users that like comedy and recommend movies for them.
All input data is publicly accessible at http://grouplens.org/datasets/movielens/
import org.apache.spark.mllib.recommendation._ // e.g. "1::595::5::978824268" / ...
%md ## Find users that like comedy
1. All five stars given by this user are for comedy movies
2. This user has given 10+ five stars
// Find the set of movie IDs that are comedy val comedyMovieIds = movies .filt ...
%md ## Train the model
// ratings RDD, rank, iterations
val model = ALS.train(ratings, 16, 10)
%md ## Recommend movies to a user that likes comedy
// Only recommend popular movies val popularMovies = ratings .map { r => (r.pr ...
displayHTML(result)
Movie recommendation with Spark ALS
Last refresh: Never