The ‘rvest’ library in R is the newest tool in my toolbox to web scrape websites! To test it out, I decided to scrape ‘Trustpilot’ website which is a popular platform for reviewers to review services and other websites. In this scraping exercise, I plan to extract reviewer ratings and remarks for Spotify. Let us see what users have to say about Spotify music!
Trustpilot website with Spotify reviews
We start by loading all the necessary libraries.
Next we create a variable to store the html of the source url which in our case is the Spotify page on the Trustpilot website.
#web-scraping #r #music #spotify #data-science