Objective: To extract the movie data from TMDB using R programming.
Step 1: Generate API Key provided by The Movie DB
The process of generating API is very simple and available to everyone for free of cost. Follow the following steps to generate personalised API Key for yourself.
i) Go to the Website.
ii) Click on the SIGN UP.
iii) After signing up and verifying your email address, go to your profile setting and click on the API tab.
Step 2: Install and load required package.
> install.packages("TMDb")
> library(TMDb)
Step 3: Explore different functions to find required data about movies.
To find the top rated movies use following code
> Top_rated_movies <- movie_top_rated(api_key, page = 1, language = "en")
>
Top_rated_movies
Setting page as 1 will give around 20 top rated movies while you can set it upto 1000. For language code refer to A ISO 639-1 codes.
To save the Top rated movies as data frame























