Death Grips is an experimental hip hop band that has been releasing innovative, interesting, and, frankly, difficult music since 2011.

Death Grips is a polarizing group — fans and many critics adore the band’s music, yet some listeners cannot stand Death Grips’ abrasive style. However, one idea with which everybody can agree is that Death Grips’ music is angry.

Whether our perception of the anger in Death Grips’ music is due to the band’s lyrics or instrumentals or purely vocalist MC Ride’s primal screaming, Death Grips is anger.

Recently, I was wondering which Death Grips songs are the most angry, and I remembered an article by Charlie Thompson in which he used Spotify audio data and Genius lyric data to try and determine which Radiohead songs and albums are the most sad.

Using a framework similar to that which Charlie used and data retrieved through the wonderful R packages spotifyr (also written by Charlie Thompson) and genius (written by Josiah Parry and used within spotifyr ), I set out to analyze Death Grips and their music in terms of anger and, ultimately, create an “Anger Index” to quickly summarize Death Grips’ angriest songs and albums.

Setting This Up (in R)

For this code-through, I’m using the programming language R. If you’ve never used R before, I’ve written a few tutorials on it.

First, you need to set up a developer account with Spotify to gain access to their API. Signing up for a Spotify developer account is free and shouldn’t take more than a few minutes or so. You can do that here.

From there, Spotify should provide you with a Client ID and a Client Secret which you can substitute instead of the "xxx" in my code.

Once this is all set-up, we’re ready to get the Death Grips song data.

Unfortunately, only Death Grips’ studio albums are on Spotify in their entirety, so this analysis only involves their studio albums (in other words, no Exmilitary).

Using the spotifyr function get_album_data() , we can retrieve Spotify audio data and Genius lyric data for each of Death Grips’ songs on their six studio albums.

Great, the data should take a minute to download, so let’s discuss anger in the mean time.

What is Anger?

We all know it when we see it, but what is anger?

The Oxford English Dictionary describes anger as a “strong feeling of annoyance, displeasure, or hostility”. So, going with that, I’d consider an angry song to be a song that exudes a “strong feeling of annoyance, displeasure, or hostility”.

But how can a song exude those feelings? A song can exude anger through sound — instrumentation, tone, screaming — and through lyrics. In other words, the level of anger in a song is a function of both the level of anger in the song’s sound and the level of anger in the song’s lyrics.

This is great, as we can do something with this framework. First, we’ll analyze the level of anger of a song purely from the song’s lyrics. Next, we’ll analyze the level of anger of a song purely from the song’s sound. Finally, we’ll put both parts together to create an “Anger Index”.

Angry Lyrics

To find how angry a song’s lyrics are, we first need to establish how we can describe a song’s lyrics as angry.

The NRC (National Research Council Canada) provides a lexicon of words tagged with a variety of emotions with which the words are strongly associated. These emotions include joy, trust, sadness, and — wait for it — anger.

Through the tidytext R package, we can find a list of words that are, by the NRC’s standards, strongly associated with anger. We can then count the number of times that these angry words appear in Death Grips songs as a proxy for how angry these songs’ lyrics are.

To do this, let’s first create a data frame of these angry words.

Using the function mutate() , we’ll add a column in the data frame indicating that all of these words are angry. This is helpful for later when we join this data frame with the data frame of Death Grips lyrics to count the number of angry words in Death Grips’ songs.

Here’s a sample of what that data frame looks like. These angry words include words like “abuse”, “abandonment”, and “abomination”.

Now that we have a data frame of angry words, we can create another data frame of Death Grips lyrics where we separate each individual word in the songs (also known as “tokenizing”) and unnest these tokens so that each row of the new data frame is a single word in each song.

This way, we can join the data frame of angry words with the data frame of Death Grips lyrics to count the number of angry words in Death Grips’ songs.

Before joining these data frames, I’m going to remove stop words from the lyrics. Stop words include words like “the”, “and”, and “for” — words that typically have little, if any, implicit meaning. Removing these words allows the focus of this analysis to be only on words that tend to contain some implicit meaning, thus providing us with a closer analysis of how angry the lyrics of these songs are.

So which Death Grips songs have the most angry words in them?

And the winner is: “Why a Bitch Gotta Lie” off of The Powers That B.

Now, we could just stop here and move on as if this is the best way to view the level of anger in a song’s lyrics, but I think there are at least two ways in which we can improve this.

Rather than using a count of the number of angry words in a song, we can view the number of angry words in a song as a percentage of the total number of words in that song. This method is an improvement because a song with 10 words, 5 of which are angry, is — in my opinion — more angry lyrically than a song with 200 words, 20 of which are angry, is.

So, which Death Grips song has the angriest lyrics in terms of the percentage of lyrics (excluding stop words) that are labeled as angry?

The winner is: “This is Violence Now (Don’t Get Me Wrong)” off of Government Plates.

Nearly 67% of the words (excluding stop words) in “This Is Violence Now” are labeled as angry words. That’s a lot. It turns out that, when you remove stop words from the song, 18 words remain.

Twelve of the remaining 18 words are “violence”.

The lyrics of “This is Violence Now (Don’t Get Me Wrong)”

Lastly, I’m going to apply the concept of “lyrical density” as discussed by Charlie Thompson in his Radiohead article article and originally cited by Myles Harrison.

Lyrical density is purely the number of words (without stop words, in this case) per second of song. We can use lyrical density to weight the “importance” of an angry word in a song. The intuition here is that a song is more angry if there are relatively many angry words in a short span of time.

By calculating the geometric mean of lyrical density and the percentage of non-stop words that are angry, we can create an equation for the anger of a song’s lyrics that equally weights the lyrical density and the “angry word percentage”.

I’ll call it the “Lyrical Anger Index”.

And we can technically cancel out the "number of words" so that this equation simplifies to:

Here’s the code (note that I re-scaled the output from the index to range from 0 to 100):

So, by the Lyrical Anger Index, which Death Grips song do you think has the angriest lyrics?

The winner is: “World of Dogs” off of No Love Deep Web.

Great. From here, let’s move onto analyzing the anger of a song in terms of the song’s sound.

Angry Sound

With Spotify’s audio data, we have many useful variables for understanding the amount of anger in a song purely in terms of the song’s sound.

One useful variable is valence . Spotify describes valence as:

“A measure from 0.0 to 1.0 describing the musical positiveness conveyed by a track. Tracks with high valence sound more positive (e.g. happy, cheerful, euphoric), while tracks with low valence sound more negative (e.g. sad, depressed, angry).”

Well, that sounds just perfect, doesn’t it? In short, a song with a low valence is more negative-sounding than a song with a high valence is.

The only issue here is that valence purely measures the “positiveness” or “negativeness” of a song; by this standard, sadness is the same as anger. But, for us, anger isn’t the same as sadness, right? Anger is a lot louder. Anger might be a bit noisier. Anger is a lot more… energetic.

Fortunately, the Spotify audio data also contains a variable called energy . Here’s what Spotify says about energy :

“Energy is a measure from 0.0 to 1.0 and represents a perceptual measure of intensity and activity. Typically, energetic tracks feel fast, loud, and noisy. For example, death metal has high energy, while a Bach prelude scores low on the scale. Perceptual features contributing to this attribute include dynamic range, perceived loudness, timbre, onset rate, and general entropy.”

Intuitively, a song that has low a valence (the song sounds negative) but has high energy (the song is loud, fast, and noisy) would represent what we understand as “angry-sounding”. This idea is even supported in an article by Jacek Grekow, “Music Emotion Maps in Arousal-Valence Space”.

Using both energy and valence , we can create an equation for the “Sonic Anger Index” by calculating the geometric mean of energy and 1 - valence (subtracting valence from 1 so that a higher value means it’s more “negative”). This way, the most angry songs will be those that are both high in energy and low in valence , while equally weighting both.

Here’s the code (note that I re-scaled the output from the index to range from 0 to 100):

So, by the Sonic Anger Index, which Death Grips songs do you think sound the most angry?

The winner is: “Bottomless Pit” off of Bottomless Pit.

Putting It All Together: The Anger Index

So, we now have a Lyrical Anger Index and a Sonic Anger Index — how can we put these two numbers together to create a single number to encapsulate the overall anger of a Death Grips song?

There are a few ways in which we can take the two indexes and turn them into one; the simplest method is to take the average (arithmetic mean) of the two indexes.

Since both indexes are on the same scale (they both range from 0 to 100), this would imply that the amount of anger in a song’s lyrics and a song’s sound equally determine the level of overall anger in that song.

But is this true?

I’d argue that the amount of anger in a song’s sound is far more important than the amount of anger in a song’s lyrics in determining the level of overall anger in a song.

By how much? I’m not quite sure.

To make sure I wasn’t alone in this thought, I asked my followers on Twitter whether the anger of a song is, generally, more determined by the amount of anger in its lyrics or the amount of anger in its sound. Here’s how they responded:

The vast majority of people responded that the anger of a song’s sound is more important.

So, how would you split the weighting of a song’s level of overall anger?

Would you say that 50% of the level of overall anger of a song can be attributed to the level of anger of its lyrics and 50% can be attributed to the level of anger of its sound? What about 20% lyrics and 80% sound?

Based on the results of the poll and my gut™, I decided to weight the level of overall anger of a song as 40% from the level of anger of that song’s lyrics and 60% from the level of anger of that song’s sound.

So, using the Sonic Anger Index and the Lyrical Anger Index we can use our weights to find the weighted arithmetic mean (in this case, more suitable than the geometric mean, in my opinion):

Here’s the code (note that I re-scaled the output from the index to range from 0 to 100):

This was all a lot of jibber jabber. What do you think Death Grips’ angriest song is, taking into account both the song’s sound and lyrics?

Drum roll, please.

…

…

And the winner is: “Giving Bad People Good Ideas” from Bottomless Pit.

I highly recommend that you not only listen to the song, but also watch the accompanying music video; it’s an experience.

Here are the top 10 songs in terms of the Anger Index:

“Shitshow” from Year Of The Snitch is second on the list, followed by “Why A Bitch Gotta Lie” and “Turned Off”.

And here are the bottom 10 songs in terms of the Anger Index:

By the Anger Index, the least angry Death Grips song is “Bootleg (Don’t Need Your Help)” followed by “Voila” and “System Blower”.

Great. Now it’s time for the real fun.

The Fun Stuff

First, let’s see the distribution of Death Grips’ songs in terms of the Anger Index. In other words, where do most songs line up?