Posts

Showing posts from May, 2020

How to Build a Spotify Playlist Recommendation Model

Image
Recognition & Credit This article and its contents were heavily influenced by Matt Dancho’s Learning Labs Pro : Session #11. Interactive Playlist Application If you are interested in creating your own playlist, please check out the Spotify Playlist Recommendation Shiny App here . Problem Statement Many companies and products you interact with every day include some type of Recommendation system. For example, the Netflix app recommends movies based on your history and what is trending. Amazon lists recommended items based on your product purchase history or what you currently have in your shopping cart.  Often, these algorithms use your data and other individuals’ data to identify groups with similar characteristics and share similar tastes. Although these algorithms are far from perfect, often, they present better recommendations than just random selection or no recommendation at all. This project aims to create a model that will produce a recommended playlist of 10 songs using...

Loading Multiple Files from Various Folders

Image
Problem Statement This tutorial shows you how to load multiple files from multiple folders using R.   As a bonus, this article will also show you how to add folder and file names to the final tibble. Load Libraries Tidyverse and readxl are the only libraries required for this tutorial. library(tidyverse) library(readxl) Data Description In this example, Spotify playlist data was downloaded using Exportify . Each .xlsx file contains information about the playlist, including the artist name, track name, album name, and song duration. A sample of one of the playlist data files is listed below. Folder Structure Each playlist was previously converted to a .xlsx file and placed into the appropriate genre’s folder. The three genre folders include Country, Hip-Hop, and Rock. Warning : please make sure to update your paths below to represent your appropriate project paths. list . dirs(path = "Data_Sources/2020_05_14_Loading_Mult_Files/Genres/" , full . names =...