We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Firefox.

Exercise: Compare populations

Compare the population growth over the last decades in the countries Austria, Hungary and Serbia.

  1. Use the data set gapminder_comparison in your ggplot() function which contains only data for the countries in question.
  2. Create a line graph with geom_line()
  3. Map the year to the x-axis and the population pop to the y-axis with aes()
  4. Map the group and the color parameter to the country variable.

Submit code to see output here.