Visualizing Kendrick Lamar’s Lyrics in Python
Kendrick Lamar is arguably the voice of today’s generation, and the most influential rapper of the 2010s. The G.O.A.T. released his latest album, Mr. Morale & the Big Steppers, on May 13th, which has debuted at №1 on the Billboard 200 album chart. I grew up listening to Kendrick Lamar since middle school and I was curious how his lyrics changed over time from a data science perspective.
After looking at word trends of hip-hop hits from 2007–2017 and visualizing how references to different trends and themes changed over time, I wanted to hone in on creating data visualizations for a single artist.
This project is done in Python. In this project, I use web scraping techniques using Beautiful Soup and the Genius API and data visualization techniques using the NTLK and Wordcloud Python packages. Specifically, I looked at lyrical richness and sentiment analysis.
Road Map:
- I. Collecting Kendrick Lamar’s discography from the Genius API
- II. Exploratory Analysis of Kendrick Lamar’s songs as a whole
- III. Collecting Kendrick Lamar’s albums from the Genius API
- IV. Lyrical Richness Album-by-Album
- V. Sentiment Analysis Album-by-Album
- VI. Summary