The Gapminder application

Now that we've got the basics, let's build a full application. Before we proceed, note that we will need to install a few packages—tidyverse, gapminder, leaflet, and ggmap. Each can be installed from CRAN (the official R package repository) using the code phrases install.packages("tidyverse"), install.packages("gapminder"), and so on. We will not install ggmap this way, though. At the time of writing, there is a bug in the CRAN version. We'll install the dev version instead, as shown in the following code:

install.packages("devtools")library(devtools)devtools::install_github("dkahle/ggmap")

The application is pretty simple to get us started, but it illustrates several important methods and principles in Shiny. It ...

Get Web Application Development with R Using Shiny - Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.