Using ggplot2 to recreate a line plot of annual temperature anomalies (CC217)

May 30, 2022 • PD Schloss • 1 min read

Pat uses tools from the ggplot2 R packge to recreate a line plot of the annual temperature anomalies by month using NASA’s GISS data. This figure shows the deviation in annual global mean temperatures from the normalized temperatures of 1951 to 1980 as a line plot. The lines are colored according to the year. He uses geom_line, scale_color_viridis_c, and a smattering of arguments from the theme function to create this provocative visual. All of this is done in R with the help of RStudio.

Code

You can browse the state of the repository at the