class: center, middle, inverse, title-slide # Data Science for Economists ## Lecture 1: Introduction ### Grant McDermott ### University of Oregon |
EC 607
--- <style type="text/css"> # CSS for including pauses in printed PDF output (see bottom of lecture) @media print { .has-continuation { display: block !important; } } </style> # Table of contents 1. [Prologue](#prologue) 2. [Syllabus highlights](#syllabus) 3. [Getting started](#started) 4. [R for data science](#r4ds) 5. [Data visualization with ggplot2](#ggplot2) --- class: inverse, center, middle name: prologue # Prologue <html><div style='float:left'></div><hr color='#EB811B' size=1px width=796px></html> --- # Introductions ### Course <svg style="height:0.8em;top:.04em;position:relative;" viewBox="0 0 496 512"><path d="M336.5 160C322 70.7 287.8 8 248 8s-74 62.7-88.5 152h177zM152 256c0 22.2 1.2 43.5 3.3 64h185.3c2.1-20.5 3.3-41.8 3.3-64s-1.2-43.5-3.3-64H155.3c-2.1 20.5-3.3 41.8-3.3 64zm324.7-96c-28.6-67.9-86.5-120.4-158-141.6 24.4 33.8 41.2 84.7 50 141.6h108zM177.2 18.4C105.8 39.6 47.8 92.1 19.3 160h108c8.7-56.9 25.5-107.8 49.9-141.6zM487.4 192H372.7c2.1 21 3.3 42.5 3.3 64s-1.2 43-3.3 64h114.6c5.5-20.5 8.6-41.8 8.6-64s-3.1-43.5-8.5-64zM120 256c0-21.5 1.2-43 3.3-64H8.6C3.2 212.5 0 233.8 0 256s3.2 43.5 8.6 64h114.6c-2-21-3.2-42.5-3.2-64zm39.5 96c14.5 89.3 48.7 152 88.5 152s74-62.7 88.5-152h-177zm159.3 141.6c71.4-21.2 129.4-73.7 158-141.6h-108c-8.8 56.9-25.6 107.8-50 141.6zM19.3 352c28.6 67.9 86.5 120.4 158 141.6-24.4-33.8-41.2-84.7-50-141.6h-108z"/></svg> https://github.com/uo-ec607 You'll soon receive access to a quarter-specific copy of this repo, where we submit assignments, upload presentations, etc. -- ### Me <svg style="height:0.8em;top:.04em;position:relative;" viewBox="0 0 448 512"><path d="M436 160c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-20V48c0-26.5-21.5-48-48-48H48C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h320c26.5 0 48-21.5 48-48v-48h20c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-20v-64h20c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-20v-64h20zm-228-32c35.3 0 64 28.7 64 64s-28.7 64-64 64-64-28.7-64-64 28.7-64 64-64zm112 236.8c0 10.6-10 19.2-22.4 19.2H118.4C106 384 96 375.4 96 364.8v-19.2c0-31.8 30.1-57.6 67.2-57.6h5c12.3 5.1 25.7 8 39.8 8s27.6-2.9 39.8-8h5c37.1 0 67.2 25.8 67.2 57.6v19.2z"/></svg> [Grant McDermott](https://grantmcdermott.com/) <svg style="height:0.8em;top:.04em;position:relative;" viewBox="0 0 512 512"><path d="M502.3 190.8c3.9-3.1 9.7-.2 9.7 4.7V400c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V195.6c0-5 5.7-7.8 9.7-4.7 22.4 17.4 52.1 39.5 154.1 113.6 21.1 15.4 56.7 47.8 92.2 47.6 35.7.3 72-32.8 92.3-47.6 102-74.1 131.6-96.3 154-113.7zM256 320c23.2.4 56.6-29.2 73.4-41.4 132.7-96.3 142.8-104.7 173.4-128.7 5.8-4.5 9.2-11.5 9.2-18.9v-19c0-26.5-21.5-48-48-48H48C21.5 64 0 85.5 0 112v19c0 7.4 3.4 14.3 9.2 18.9 30.6 23.9 40.7 32.4 173.4 128.7 16.8 12.2 50.2 41.8 73.4 41.4z"/></svg> [grantmcd@uoregon.edu](mailto:grantmcd@uoregon.edu) <svg style="height:0.8em;top:.04em;position:relative;" viewBox="0 0 640 512"><path d="M622.34 153.2L343.4 67.5c-15.2-4.67-31.6-4.67-46.79 0L17.66 153.2c-23.54 7.23-23.54 38.36 0 45.59l48.63 14.94c-10.67 13.19-17.23 29.28-17.88 46.9C38.78 266.15 32 276.11 32 288c0 10.78 5.68 19.85 13.86 25.65L20.33 428.53C18.11 438.52 25.71 448 35.94 448h56.11c10.24 0 17.84-9.48 15.62-19.47L82.14 313.65C90.32 307.85 96 298.78 96 288c0-11.57-6.47-21.25-15.66-26.87.76-15.02 8.44-28.3 20.69-36.72L296.6 284.5c9.06 2.78 26.44 6.25 46.79 0l278.95-85.7c23.55-7.24 23.55-38.36 0-45.6zM352.79 315.09c-28.53 8.76-52.84 3.92-65.59 0l-145.02-44.55L128 384c0 35.35 85.96 64 192 64s192-28.65 192-64l-14.18-113.47-145.03 44.56z"/></svg> Assistant Professor (environmental economics and data science) -- ### You A quick roundtable of names, fields/interests, and coding background. --- class: inverse, center, middle name: syllabus # Syllabus highlights <html><div style='float:left'></div><hr color='#EB811B' size=1px width=796px></html> (Read the full document [here](https://github.com/uo-ec607/syllabus/blob/master/syllabus.pdf).) --- # Why this course? Fill in the gaps left by traditional econometrics and methods classes. - Practical skills that tools that will benefit your dissertation and future career. - Neglected skills like how to actually find datasets in the wild and clean them. Data science skills are largely distinct from (and complementary to) the core 'metrics oeuvre familiar to economists. - Data viz, cleaning and wrangling; programming; cloud computation; relational databases; machine learning; etc. -- > *"In short, we will cover things that I wish someone had taught me when I was starting out in graduate school."* --- # You, at the end of this course <div align="center"> <img src="pics/awesome.jpg"> </div> --- # Grading | Component | Weight | |:-|-:| | 4 × homework assignments (20% each) | 80% | | 2 × short presentations (5% each) | 10% | | 1 × OSS contribution | 10% | - You can swap out one homework assignment for an (approved) final presentation of your own research. - [Short presentations](https://github.com/uo-ec607/presentations) summarize either a key lecture reading, or an (approved) software package/platform. - We'll get to OSS contribution later in the course, but I particularly encourage contributions to [LOST](lost-stats.github.io/). -- </br> PS — I'll also award a class participation bonus (2.5%) at my discretion. --- # Lecture outline ### Data science basics - Introduction: Motivation, software installation, and data visualization - Version control with Git(Hub) - Learning to love the shell - R language basics - Data cleaning and wrangling: 1) tidyverse and 2) data.table - Webscraping: (1) Server-side and CSS - Webscraping: (2) Client-side and APIs ### Analysis and programming - Regression analysis in R - Spatial analysis in R - Functions in R: (1) Introductory concepts - Functions in R: (2) Advanced concepts - Parallel programming --- # Lecture outline (cont.) ### Scaling up: Big data and cloud computation - Docker - Cloud computing with Google Compute Engine - High performance computing (Talapas cluster) - Databases: SQL(ite) and BigQuery - Spark - **Options** - Project workflow and automation - Machine learning - Peer-review and student project presentations (demand dependent) --- class: inverse, center, middle name: started # Getting started <html><div style='float:left'></div><hr color='#EB811B' size=1px width=796px></html> --- # Software installation and registration 1. Download [R](https://www.r-project.org/). 2. Download [RStudio](https://www.rstudio.com/products/rstudio/download/preview/). 3. Download [Git](https://git-scm.com/downloads). 4. Create an account on [GitHub](https://github.com/) and register for a student/educator [discount](https://education.github.com/discount_requests/new). - You will soon receive an invitation to the quarter-specific course org. on GitHub, as well as [GitHub classroom](https://classroom.github.com), which is how we'll disseminate and submit assignments, receive feedback and grading, etc. -- If you had trouble completing any of these steps, please raise your hand. - My go-to place for installation guidance and troubleshooting is Jenny Bryan's http://happygitwithr.com. --- # Some OS-specific extras I'll detail further software requirements as and when the need arises. However, to help smooth some software installation issues further down the road, please also do the following (depending on your OS): - **Windows:** Install [Rtools](https://cran.r-project.org/bin/windows/Rtools/). I also recommend that you install [Chocolately](https://chocolatey.org/). - **Mac:** Install [Homebrew](https://brew.sh/). I also recommend that you configure/open your C++ toolchain (see [here](https://github.com/rmacoslib/r-macos-rtools#installer-package-for-macos-r-toolchain-).) - **Linux:** None (you should be good to go). --- # Checklist ☑ Do you have the most recent version of R? ```r version$version.string ``` ``` ## [1] "R version 4.0.4 (2021-02-15)" ``` ☑ Do you have the most recent version of RStudio? (The [preview version](https://www.rstudio.com/products/rstudio/download/preview/) is fine.) ```r RStudio.Version()$version ## Requires an interactive session but should return something like "[1] ‘1.4.1100’" ``` ☑ Have you updated all of your R packages? ```r update.packages(ask = FALSE, checkBuilt = TRUE) ``` --- # Checklist (cont.) Open up the [shell](http://happygitwithr.com/shell.html#shell). - Windows users, make sure that you installed a Bash-compatible version of the shell. If you installed [Git for Windows](https://gitforwindows.org), then you should be good to go. ☑ Which version of Git have you installed? ```bash git --version ``` ``` ## git version 2.30.1 ``` ☑ Did you introduce yourself to Git? (Substitute in your details.) ```bash git config --global user.name 'Grant McDermott' git config --global user.email 'grantmcd@uoregon.edu' git config --global --list ``` ☑ Did you register an account in GitHub? --- # Checklist (cont.) We will make sure that everything is working properly with your R and GitHub setup next lecture. For the rest of today's lecture, I want to go over some very basic R concepts. -- </br> PS — Just so you know where we're headed: We'll return to these R concepts (and delve much deeper) next week after a brief, but important detour to the lands of Git(Hub) and the shell. - Don't worry, it will all make sense. You'll see. --- class: inverse, center, middle name: r4ds # R for data science <html><div style='float:left'></div><hr color='#EB811B' size=1px width=796px></html> --- name: whyr # Why R and RStudio? (cont.) <img src="01-Intro_files/figure-html/indeeddotcom-1.svg" style="display: block; margin: auto;" /> --- # Why R and RStudio? (cont.) ### Data science positivism - Alongside Python, R has become the *de facto* language for data science. - See: [*The Impressive Growth of R*](https://stackoverflow.blog/2017/10/10/impressive-growth-r/), [*The Popularity of Data Science Software*](http://r4stats.com/articles/popularity/) - Open-source (free!) with a global user-base spanning academia and industry. - "Do you want to be a profit source or a cost center?" ### Bridge to applied economics and other tools - Already has all of the statistics and econometrics support, and is amazingly adaptable as a “glue” language to other programming languages and APIs. - The RStudio IDE and ecosystem allow for further, seemless integration. ### Path dependency - It's also the language that I know best. -- - (Learning multiple languages is a good idea, though.) --- # Some R basics 1. Everything is an object. 2. Everything has a name. 3. You do things using functions. 4. Functions come pre-written in packages (i.e. "libraries"), although you can — and should — write your own functions too. -- </br> Points 1. and 2. can be summarised as an [object-orientated programming](https://en.wikipedia.org/wiki/Object-oriented_programming) (OOP) approach. - This may sound super abstract now, but we'll see *lots* of examples over the coming weeks that will make things clear. --- # R vs Stata If you're coming from Stata, some additional things worth emphasizing: - Multiple objects (e.g. data frames) can exist happily in the same workspace. - No more `keep`, `preserve`, `restore` hackery. (Though, props to [Stata 16](https://www.stata.com/new-in-stata/multiple-datasets-in-memory/).) - This is a direct consequence of the OOP approach. - You will load packages at the start of every new R session. Make peace with this. - "Base" R comes with tons of useful in-built functions. It also provides all the tools necessary for you to write your own functions. - However, many of R's best data science functions and tools come from external packages written by other users. - R easily and infinitely parallelizes. For free. - Compare the cost of a [Stata/MP](https://www.stata.com/statamp/) license, nevermind the fact that you effectively pay per core... - You don't need to `tset or xtset` your data. (Although you can too.) --- # R code example (linear regression) ```r fit = lm(mpg ~ wt, data = mtcars) summary(fit) ``` ``` ## ## Call: ## lm(formula = mpg ~ wt, data = mtcars) ## ## Residuals: ## Min 1Q Median 3Q Max ## -4.5432 -2.3647 -0.1252 1.4096 6.8727 ## ## Coefficients: ## Estimate Std. Error t value Pr(>|t|) ## (Intercept) 37.2851 1.8776 19.858 < 2e-16 *** ## wt -5.3445 0.5591 -9.559 1.29e-10 *** ## --- ## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1 ## ## Residual standard error: 3.046 on 30 degrees of freedom ## Multiple R-squared: 0.7528, Adjusted R-squared: 0.7446 ## F-statistic: 91.38 on 1 and 30 DF, p-value: 1.294e-10 ``` --- # Base R plot ```r par(mar = c(4, 4, 1, .1)) ## Just for nice plot margins on this slide deck plot(mtcars$wt, mtcars$mpg) abline(fit, col = "red") ``` <img src="01-Intro_files/figure-html/mtcars_baseplot-1.svg" style="display: block; margin: auto;" /> --- # ggplot2 ```r library(ggplot2) ggplot(data = mtcars, aes(x = wt, y = mpg)) + geom_smooth(method = "lm", col = "red") + geom_point() ``` <img src="01-Intro_files/figure-html/mtcars_ggplot-1.svg" style="display: block; margin: auto;" /> --- class: inverse, center, middle name: ggplot2 # More ggplot2 <html><div style='float:left'></div><hr color='#EB811B' size=1px width=796px></html> --- # Install and load Open up your laptops. For the remainder of this first lecture, we're going continue playing around with [ggplot2](https://ggplot2.tidyverse.org/) (i.e. livecoding). If you don't have them already, install the `ggplot2` and `gapminder` packages via either: - **Console:** Enter `install.packages(c("ggplot2", "gapminder"), dependencies=T)`. - **RStudio:** Click the "Packages" tab in the bottom-right window pane. Then click "Install" and search for these two packages. ![](pics/install.gif) --- # Install and load (cont.) Once the packages are installed, load them into your R session with the `library()` function. ```r library(ggplot2) library(gapminder) ## We're just using this package for the gapminder data ``` Notice too that you don't need quotes around the package names any more. Reason: R now recognises these packages as defined objects with given names. ("Everything in R is an object and everything has a name.") -- PS — A convenient way to combine the package installation and loading steps is with the [pacman package's](https://github.com/trinker/pacman) `p_load()` function. If you run `pacman::p_load(ggplot, gapminder)` it will first look to see whether it needs to install either package before loading them. Clever. - We'll get to this next week, but if you want to run a function from an (installed) package without loading it, you can use the `PACKAGE::package_function()` syntax. --- # Brief aside: The gapminder dataset Because we're going to be plotting the [gapminder](https://github.com/jennybc/gapminder) dataset, it is helpful to know that it contains panel data on life expectancy, population size, and GDP per capita for 142 countries since the 1950s. ```r gapminder ``` ``` ## # A tibble: 1,704 x 6 ## country continent year lifeExp pop gdpPercap ## <fct> <fct> <int> <dbl> <int> <dbl> ## 1 Afghanistan Asia 1952 28.8 8425333 779. ## 2 Afghanistan Asia 1957 30.3 9240934 821. ## 3 Afghanistan Asia 1962 32.0 10267083 853. ## 4 Afghanistan Asia 1967 34.0 11537966 836. ## 5 Afghanistan Asia 1972 36.1 13079460 740. ## 6 Afghanistan Asia 1977 38.4 14880372 786. ## 7 Afghanistan Asia 1982 39.9 12881816 978. ## 8 Afghanistan Asia 1987 40.8 13867957 852. ## 9 Afghanistan Asia 1992 41.7 16317921 649. ## 10 Afghanistan Asia 1997 41.8 22227415 635. ## # … with 1,694 more rows ``` --- # Elements of ggplot2 [Hadley Wickham's](http://hadley.nz/) ggplot2 is one of the most popular packages in the entire R canon. - It also happens to be built upon some deep visualization theory: i.e. Leland Wilkinson's [*The Grammar of Graphics*](https://www.amazon.com/Grammar-Graphics-Statistics-Computing/dp/0387245448). There's a lot to say about ggplot2's implementation of this "grammar of graphics" approach, but the three key elements are: 1. Your plot ("the visualization") is linked to your variables ("the data") through various **aesthetic mappings**. 2. Once the aesthetic mappings are defined, you can represent your data in different ways by choosing different **geoms** (i.e. "geometric objects" like points, lines or bars). 3. You build your plot in **layers**. -- </br> That's kind of abstract. Let's review each element in turn with some actual plots. --- # 1. Aesthetic mappings ```r ggplot(data = gapminder, mapping = aes(x = gdpPercap, y = lifeExp)) + geom_point() ``` <img src="01-Intro_files/figure-html/aesthetics0-1.png" style="display: block; margin: auto;" /> --- # 1. Aesthetic mappings (cont.) ```r ggplot(data = gapminder, mapping = aes(x = gdpPercap, y = lifeExp)) + geom_point() ``` Focus on the top line, which contains the initialising `ggplot()` function call. This function accepts various arguments, including: - Where the data come from (i.e. `data = gapminder`). - What the aesthetic mappings are (i.e. `mapping = aes(x = gdpPercap, y = lifeExp)`). -- The aesthetic mappings here are pretty simple: They just define an x-axis (GDP per capita) and a y-axis (life expecancy). - To get a sense of the power and flexibility that comes with this approach, however, consider what happens if we add more aesthetics to the plot call... --- # 1. Aesthetic mappings (cont.) ```r ggplot(data = gapminder, aes(x = gdpPercap, y = lifeExp, size = pop, col = continent)) + geom_point(alpha = 0.3) ## "alpha" controls transparency. Takes a value between 0 and 1. ``` <img src="01-Intro_files/figure-html/aesthetics2-1.svg" style="display: block; margin: auto;" /> -- Note that I've dropped the "mapping =" part of the ggplot call. Most people just start with "aes(...)", since `ggplot2` knows the order of the arguments. --- # 1. Aesthetic mappings (cont.) We can specify aesthetic mappings in the geom layer too. ```r ggplot(data = gapminder, aes(x = gdpPercap, y = lifeExp)) + ## Applicable to all geoms geom_point(aes(size = pop, col = continent), alpha = 0.3) ## Applicable to this geom only ``` <img src="01-Intro_files/figure-html/aesthetics3-1.svg" style="display: block; margin: auto;" /> --- # 1. Aesthetic mappings (cont.) Oops. What went wrong here? ```r ggplot(data = gapminder, aes(x = gdpPercap, y = lifeExp)) + geom_point(aes(size = "big", col="black"), alpha = 0.3) ``` <img src="01-Intro_files/figure-html/aesthetics_mistake-1.svg" style="display: block; margin: auto;" /> -- **Answer: **Aesthetics must be mapped to variables, not descriptions! --- # 1. Aesthetic mappings (cont.) At this point, instead of repeating the same ggplot2 call every time, it will prove convenient to define an intermediate plot object that we can re-use. ```r p = ggplot(data = gapminder, aes(x = gdpPercap, y = lifeExp)) p ``` <img src="01-Intro_files/figure-html/p-1.svg" style="display: block; margin: auto;" /> --- # 2. Geoms Once your variable relationships have been defined by the aesthetic mappings, you can invoke and combine different geoms to generate different visulaizations. ```r p + geom_point(alpha = 0.3) + geom_smooth(method = "loess") ``` <img src="01-Intro_files/figure-html/geoms1-1.svg" style="display: block; margin: auto;" /> --- # 2. Geoms (cont.) Aesthetics can be applied differentially across geoms. ```r p + geom_point(aes(size = pop, col = continent), alpha = 0.3) + geom_smooth(method = "loess") ``` <img src="01-Intro_files/figure-html/geoms2-1.svg" style="display: block; margin: auto;" /> --- # 2. Geoms (cont.) The previous plot provides a good illustration of the power (or effect) that comes from assigning aesthetic mappings "globally" vs in the individual geom layers. - Compare: What happens if you run the below code chunk? ```r ggplot(data = gapminder, aes(x = gdpPercap, y = lifeExp, size = pop, col = continent)) + geom_point(alpha = 0.3) + geom_smooth(method = "loess") ``` --- # 2. Geoms (cont.) Similarly, note that some geoms only accept a subset of mappings. E.g. `geom_density()` doesn't know what to do with the "y" aesthetic mapping. ```r p + geom_density() ``` ``` ## Error: geom_density requires the following missing aesthetics: y ``` <img src="01-Intro_files/figure-html/geoms4-1.svg" style="display: block; margin: auto;" /> --- # 2. Geoms (cont.) We can fix that by being more careful about how we build the plot. ```r ggplot(data = gapminder) + ## i.e. No "global" aesthetic mappings" geom_density(aes(x = gdpPercap, fill = continent), alpha=0.3) ``` <img src="01-Intro_files/figure-html/geoms5-1.svg" style="display: block; margin: auto;" /> --- # 3. Build your plot in layers We've already seen how we can chain (or "layer") consecutive plot elements using the `+` connector. - The fact that we can create and then re-use an intermediate plot object (e.g. "p") is testament to this. But it bears repeating: You can build out some truly impressive complexity and transformation of your visualization through this simple layering process. - You don't have to transform your original data; ggplot2 takes care of all of that. - For example (see next slide for figure). ```r p2 = p + geom_point(aes(size = pop, col = continent), alpha = 0.3) + scale_color_brewer(name = "Continent", palette = "Set1") + ## Different colour scale scale_size(name = "Population", labels = scales::comma) + ## Different point (i.e. legend) scale scale_x_log10(labels = scales::dollar) + ## Switch to logarithmic scale on x-axis. Use dollar units. labs(x = "Log (GDP per capita)", y = "Life Expectancy") + ## Better axis titles theme_minimal() ## Try a minimal (b&w) plot theme ``` --- # 3. Build your plot in layers (cont.) <img src="01-Intro_files/figure-html/layers2-1.svg" style="display: block; margin: auto;" /> --- # What else? We have barely scratched the surface of ggplot2's functionality... let alone talked about the entire ecosystem of packages that has been built around it. - Here's are two quick additional examples to whet your appetite -- Note that you will need to install and load some additional packages if you want to recreate the next two figures on your own machine. A quick way to do this: ```r if (!require("pacman")) install.packages("pacman") pacman::p_load(hrbrthemes, gganimate) ``` --- # What else? (cont.) Simple extension: Use an external package theme. ```r # library(hrbrthemes) p2 + theme_modern_rc() + geom_point(aes(size = pop, col = continent), alpha = 0.2) ``` <img src="01-Intro_files/figure-html/modern_rc_theme-1.svg" style="display: block; margin: auto;" /> --- # What else? (cont.) Elaborate extension: Animation! (See the next slide for the resulting GIF.) ```r # library(gganimate) ggplot(gapminder, aes(gdpPercap, lifeExp, size = pop, colour = country)) + geom_point(alpha = 0.7, show.legend = FALSE) + scale_colour_manual(values = country_colors) + scale_size(range = c(2, 12)) + scale_x_log10() + facet_wrap(~continent) + # Here comes the gganimate specific bits labs(title = 'Year: {frame_time}', x = 'GDP per capita', y = 'life expectancy') + transition_time(year) + ease_aes('linear') ``` --- # What else? (cont.) <img src="01-Intro_files/figure-html/ggamin2-1.gif" style="display: block; margin: auto;" /> -- Note that this animated plot provides a much more intuitive understanding of the underlying data. Just as [Hans Rosling](https://www.ted.com/talks/hans_rosling_the_best_stats_you_ve_ever_seen) intended. --- # What else? (cont.) There's a lot more to say, but I think we'll stop now for today's lecture. We also haven't touched on ggplot2's relationship to "tidy" data. - It actually forms part of a suite of packages collectively known as the [tidyverse](https://www.tidyverse.org/). - We will get back to this in Lecture 5. Rest assured, you will be using ggplot2 throughout the rest of this course and developing your skills along the way. - Your very first assignment (coming up) is a chance specifically to hone some of those skills. In the meantime, I want you to do some reading and practice on your own. Pick either of the following (or choose among the litany of online resources) and work through their examples: - [Chapter 3](https://r4ds.had.co.nz/data-visualisation.html) of *R for Data Science* by Hadley Wickham and Garett Grolemund. - [*Data Visualization: A Practical Guide*](https://socviz.co/makeplot.html) by Kieran Healy. - [Designing ggplots](https://designing-ggplots.netlify.com) by Malcom Barrett. --- class: inverse, center, middle # Next lecture: Deep dive into Git(Hub). <html><div style='float:left'></div><hr color='#EB811B' size=1px width=796px></html>