Hans Rosling is one of the most popular data scientists on the web. His original TED talk was very popular among my friends when it came out. We are going to create some graphics using his formatted data as our weekly case study. Note that we need to remove Kuwait from the data (discussion on this)
This reading will help you complete the tasks below.
library(gapminder)(get them to match as closely as you can)
library(tidyverse)to load ggplot2 and dplyr and the
theme_bw()to duplicate the first plot
scale_y_continuous(trans = "sqrt")to get the correct scale on the y-axis.
weighted.mean()and GDP with
group_by()that will be the black continent average line on the second plot
theme_bw()to duplicate the second plot. You will need to use the new data to make the black lines and dots showing the continent average.
ggsave()and save each plot as a
.pngwith a width of 15 inches
.md, and the two
.png’s of the plots into your git repository.