Monday, January 27, 2025

Looking at Song Popularity

The popularity of musical genres has changes quite a bit of the years... and yet in many ways it's stayed constant. Looking at the data pulled together by Marianos Silver (called 'MusicOSet'), which calculates song and artist popularity based on Billboard chart success and radio and Spotify plays, the least popular music in the years 1960 to 2019 was, perhaps unsurprisingly, 'Bagpipe'! 'Halloween' also scored badly. 'Country Dawn' had the worst single score but featured in more than one decade. Figure 4.1 shows the five least popular musical genres by decade. 

Fig. 4.1. Least popular musical popular by decade

For the most popular genres, ‘Album Rock’ and ‘Dance Pop’ had the highest ratings overall. Album Rock features in the top 5 most popular genres from the 1960’s to the 1990’s. Dance Pop is in the top 5 most popular from the 1990’s to the 2010’s. 

Another way of looking at musical genre is a treemap (figure 4.2). Here we can see a mapping of genre where the area is proportional to the popularity and colours correspond to artist type. Both Dance Pop and Album Rock are present in the 'Singer' and Band' genres.

Fig 4.2. Treemap showing artist genre by artist type










Monday, January 20, 2025

Text Mining and Representing Tweets

I've been investigating text mining through the recommended book (Kwartler, 2017). Some interesting processing on Delta airlines support tweets to remove stopwords and punctuation, lowercase the data. Then from the processed block of tweets a 'Term Document Matrix', or TDM was made. This is a list of words and the frequency of where they appear. The diagram essentially shows the way certain words cluster together. The 'Height' represents the "distance" between words in the matrix. 

Figure 1.1. Dendrogram from Delta airlines tweets

Another way to look at this is by colouring the branches. Representing the dendrogram in a circle gives a different perspective too (Fig 1.2). 


Figure 1.2 Circular dendrogram from Delta airlines tweets

I should reiterate that whilst these dendrograms formed the basis of my understanding, they are worked examples from Ted Kwartler's book. I just thought they looked cool!

References

Kwartler, T. (2017). Text mining in practice with R. John Wiley & Sons.

Evaluating Embeddings for NLP and Document Clustering

Embeddings are an alternative to traditional methods of vectorisation first proposed by Bengio et al in 2003, who developed the first langua...