In this unit, you will become familiar with the R console, RStudio, and basic actions and operations in R.
Follow the links to each lecture, lab, and reading.
Scroll down to download the SWIRL lessons.
Lecture: Overview of R, demonstration of R.
Lab: Unit 1: Lab 1
Reading: NYT article
SWIRL: Basic building blocks
Lab: Unit 1: Lab 2
Lecture: Types of data and data structures
Best Practice: Code style guide
Lecture: Using functions
Lab: Unit 1: Recap
The lessons we will use are available online and you need to download them to your laptop.
In the console panel, next to the arrow (>), copy and paste the following:
library(swirl) install_course_github("intro2r", "swirl_courses", multi = TRUE)
This will download the most up-to-date lessons.
To start the lesson, type