Analysis

Goals of this notebook

Exploring the Billboard Hot 100 charts data.

  • Which performer had the most appearances on the Hot 100 chart at any position?
  • Which song (title & performer) has been on the charts the most?
  • Which song (title & performer) was No. 1 for the most number of weeks?
  • Which performer had the most songs reach No. 1?
  • Which performer had the most songs reach No. 1 in the most recent five years?
  • Which performer has had the most Top 10 hits overall?

Setup

library(tidyverse)
── Attaching core tidyverse packages ──────────────────────── tidyverse 2.0.0 ──
✔ dplyr     1.1.2     ✔ readr     2.1.4
✔ forcats   1.0.0     ✔ stringr   1.5.0
✔ ggplot2   3.4.3     ✔ tibble    3.2.1
✔ lubridate 1.9.2     ✔ tidyr     1.3.0
✔ purrr     1.0.2     
── Conflicts ────────────────────────────────────────── tidyverse_conflicts() ──
✖ dplyr::filter() masks stats::filter()
✖ dplyr::lag()    masks stats::lag()
ℹ Use the conflicted package (<http://conflicted.r-lib.org/>) to force all conflicts to become errors

Importing Clean Data

hot100 <- read_rds("data-processed/01-hot100.rds")

hot100 |> glimpse()
Rows: 341,800
Columns: 7
$ chart_date    <date> 1958-08-04, 1958-08-04, 1958-08-04, 1958-08-04, 1958-08…
$ current_rank  <dbl> 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 1…
$ title         <chr> "Poor Little Fool", "Patricia", "Splish Splash", "Hard H…
$ performer     <chr> "Ricky Nelson", "Perez Prado And His Orchestra", "Bobby …
$ previous_rank <dbl> NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, …
$ peak_rank     <dbl> 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 1…
$ wks_on_chart  <dbl> 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,…

Most Appearances

Which performer had the most appearances on the Hot 100 chart at any position?

hot100 |>
  group_by(performer) |>
  summarize(appearances = n()) |>
  arrange(desc(appearances)) |>
  head(10)

Data Takeaway: Taylor Swift has more appearances on the Billboard Hot 100 than any other artist in history, excluding collaborations among multiple artists. Through 2023, she has 1,386 appearances.

Song with most appearances

Which song (title & performer) has been on the charts the most?

hot100 |>
  group_by(performer, title) |>
  summarize(appearances = n()) |>
  arrange(desc(appearances)) |>
  filter(appearances >= 65)
`summarise()` has grouped output by 'performer'. You can override using the
`.groups` argument.

Data Takeaway: The song “Heat Wave” by Glass Animals has appeared 91 times on the Billboard Hot 100 chart, more than any other song through 2023. The Weeknd’s “Blinding Lights” has the next most appearances with 90.

Song the longest at No. 1

Which song (title & performer) was No. 1 for the most number of weeks?

hot100 |> 
  filter(current_rank == 1) |>
  group_by(performer, title) |>
  summarize(appearances =n()) |>
  arrange(desc(appearances)) |>
  filter(appearances >=15)
`summarise()` has grouped output by 'performer'. You can override using the
`.groups` argument.

The song “Old Town Road” by Lil Nas X Featuring Billy Ray Cyrus has spent more time at the top of the Billboard Hot 100 than any other song in history at 19 weeks.

Performer with most No.1 singles

Which performer had the most titles reach No. 1?

hot100 |> 
  filter(current_rank == 1) |>
  distinct(title, performer) |>
  group_by(performer) |>
  summarize(no1_hits = n()) |>
  arrange(no1_hits |> desc()) |>
  filter(no1_hits >=10)

The Beatles have the most No. 1 hits on the Billboard Hot 100 charts with 19, but they also have a 20th top song – “Get Back” – that is a collaboration with Billy Preston. Most other artists with double-digit top hits aren’t making new music, with the exception of Taylor Swift, who has 10.

Most No.1 hits in last five years

Which performer had the most songs reach No. 1 in the most recent five years?

hot100 |>
  filter(current_rank == 1,
  chart_date > "2017-12-31") |>
  distinct(title, performer) |>
  group_by(performer) |>
  summarize(top_hits = n()) |>
  arrange(top_hits |> desc()) |>
  filter(top_hits > 1)

Taylor Swift not only has the most appearances of all time in the Hot 100, she also has the most No. 1 hits in the past five years with six.

Most Top 10 hits

Which performer had the most Top 10 hits overall?

hot100 |>
  filter(current_rank >= 1 & current_rank <= 10) |>
  group_by(performer) |>
  summarize(top10_hits = n()) |>
  arrange(top10_hits |> desc()) |>
  head(10)

Data Takeaway: Mariah Carey has the most Top 10 hits with 250 overall.

Most appearances in 2003

Who had the most appearances in 2003?

hot100 |>
  filter(year(chart_date) == "2003") |>
  filter(current_rank >= 1 & current_rank <= 10) |>
  group_by(performer)|>
  summarize(appearances = n())|>
  arrange(desc(appearances)) |>
  head(10)

I used filter and specifically year to pull the year 2003 and performers within the top ten rank. I then grouped by performer and summarized how many appearances they had, and those with the most, arranged in a top ten format. I then use head to only show 10 rows.

Data Takeaway: 50 Cent had the most appearances on the Top Ten during the year 2003.