Skip to content

Spotify Analysis


                       


Analyse your Spotify Streaming data and get some insights from it like whom & when you listen your favorite Tracks, Artists, Playlists or Albums.
Created Jupyter Notebook where you can upload your data and get the analysis by running the notebook.

How to get my Spotify data?

You can request your Spotify data from official website.

Know more about your personal data on Spotify.

Spotify data file structure
spotify-data
├── Read_Me_First.pdf         # Introductory document
├── Follow.json               # Data about user's followers
├── Identifiers.json          # Identification information (🙅 Do Not Share!)
├── Identity.json             # User identity details (🙅 Do Not Share!)
├── Inferences.json           # Inferred data from user activity
├── Marquee.json              # Marquee-related information
├── Payments.json             # Payment details (🙅 Do Not Share!)
├── Playlist1.json            # Details about a specific playlist
├── SearchQueries.json        # User's search queries
├── StreamingHistory0.json    # User's Streaming history part 1
├── StreamingHistory1.json    # User's Streaming history part 2
├── Userdata.json             # General user data (🙅 Do Not Share!)
└── YourLibrary.json          # User's Spotify library details like likes, albums, artists, etc.

Philosophy

I want to analyse my Spotify's Streaming History in a way from which I can know my listening pattern over the time. The way Spotify give the Spotify Wrapped at the end of every year.

The Dashboard

Currently not developed!

If you want to join for this contact me on my socials

There has been a dashboard (using Streamlit) where other users can upload their StreamingHistory.json files to see analysis on their history.

Some Awesome Insights

To gather insights from json files I've used polars and their builtin .plot accessor which uses hvplot library under-the-hood.

See the Jupyter Notebooks to see all the insights.

Reference
ShortCode Description
T/A Track/Artist
T/As Track/Artist(s)
P/A Playlist/Album
P/As Playlist/Album(s)

These shortcodes used below for better readability.

Using StreamingHistory.json

File Info

Contains User's Streaming History with trackName, artistName, msPlayed and endTime.  

  • Top T/As in whole dataset.
  • Top T/As in each month.
  • Monthly most listend Tracks and Artists.
  • First day when T/A was played.
  • No.of distinct T/As listened in each month/year.
  • A T/A streaming in barplot (which shows how you stream that during time-to-time).
  • Which daytime user listen most and whom.
  • Tracks which have listened most times in a day.
  • Tracks streaming streak (by day/week).
  • T/As which only played once
  • Dates when user does not played any track

Using Playlist.json

File Info

Contains User's Created Playlist Data with all the tracks added in the playlist.

  • No. of T/As and Albums in each Playlist
  • Playlist MinutesPlayed
  • Most streamed P/As
  • Check any Track present in multiple Playlists
  • Streaming timline of P/As (with plot.line())
  • Playlist-wise top T/As

Using YourLibrary.json

Currently Working!

Using Marquee.json

Currently Working!