Session Ready
Exercise

Zero Olympic medals

Since 1896, athletes from all over the world have been competing in the modern Olympic games. You've been given a dataset (medal_df) with observations for all medals won by athletes from the 10 most successful countries in Olympic history. You want to create a visual with the number of medals won per country (team) per year. However, since not all countries won medals each year, you'll have to introduce zero values before you can make an accurate visual.

Olympic flag

The ggplot2 and dplyr packages have been pre-loaded for you. In step 2 and 3 the scale_color_brewer() function is used to color lines in the plot with a palette that makes it easier to distinguish the different countries.

Instructions 1/3
undefined XP
  • 1
  • 2
  • 3
  • Inspect medal_df in the console.
  • Count the number of medals won per team and year.