Session Ready
Exercise

Gather & plot non-sequential columns

In this exercise, you'll combine tidyr with dplyr::select() to keep and gather non-sequential columns in the ratings2 data. You can review the select helper functions here. The ratings2 data includes per-episode data:

  • e*_7day: viewers within a 7-day window, and
  • e*_28day: viewers within a 28-day window.

Here, we'll focus on the 7-day viewers.

Instructions 1/3
undefined XP
  • 1
  • 2
  • 3
  • Create a new data frame called week_ratings, selecting the variables you will need from ratings2 to plot only the 7-day viewers by episode and series.