Session Ready
Exercise

Multi-Layer Plot 2 (Scatter + Line Plot)

rbokeh figures can be assigned to objects and modified afterwards, which gives you the flexibility to look at intermediate figures and build them layer by layer.

In this exercise, you will practice modifying rbokeh figures by creating a line plot, assigning it to fig_countries, then adding a points layer on top.

You will use a subset of the gapminder dataset that includes data for two Asian countries ("India", "China").

Note that:

  • gapminder and dplyr and rbokeh packages are pre-loaded.
Instructions 1/3
undefined XP
  • 1
  • 2
  • 3
  • Extract the records of "China" and "India" from gapminder using filter().