1. Learn
  2. /
  3. Courses
  4. /
  5. Introduction to Tidyverse - Review

Exercise

(SAMPLE ITERATIVE) Rename and reorder variables

In the previous exercise, you renamed all the variables in ratings that end with "7day" and kept only a subset of variables. In this exercise, you'll adapt that code to drop some specific columns, while keeping and reordering other columns.

Instructions 1/2

undefined XP
  • 1

    Drop the ten columns that contain 28-day viewer data and keep all the viewers7day variables in the front.

  • 2

    Adapt your code to now keep the original order of the variables, with the conditions in the last part still relevant.