Before Day 1: Getting Set Up for R Lab
Everything you need to install before our first class
1 Install R
R is the statistical programming language we’ll use throughout this course. You need to install it first before installing RStudio or Positron.
- Go to https://cran.r-project.org
- Click Download R for your operating system (Windows, macOS, or Linux)
- Follow the installer instructions
- Open the R application once to confirm it installed correctly, you should see the R console
Which version? Always download the latest release. As of this writing that is R 4.5.3.
2 Development Environment
You’ll want an Integrated Development Environment (IDE) to write and run your R code comfortably. We recommend Positron, though RStudio is a perfectly fine alternative.
2.1 Option A: Positron (Preferred)
Positron is a next-generation data science IDE built by Posit (the same team behind RStudio). It’s built on VS Code and offers a modern, flexible environment for R and Python.
- Go to https://github.com/posit-co/positron/releases
- Download the latest release for your operating system
- Install and open Positron
- Open a new R file and run
1 + 1to confirm R is connected
Why Positron? Positron has a cleaner interface, better multi-language support, and is the direction the R ecosystem is heading. We’ll be using it in class demos.
2.2 Option B: RStudio
RStudio is the classic, battle-tested R IDE and is a great choice if you prefer something more established.
- Go to https://posit.co/download/rstudio-desktop/
- Scroll down and download the free RStudio Desktop version for your OS
- Install and open RStudio
- In the Console pane, type
1 + 1and press Enter to confirm R is working
Either IDE will work fine for this course. Just pick one and stick with it!
3 Create a GitHub Account
We’ll use GitHub to share code, submit assignments, and practice version control.
- Go to https://github.com
- Click Sign up and create a free account
- Choose a username
- Verify your email address
4 Install GitHub Desktop
GitHub Desktop gives you a visual interface for working with Git and GitHub.
- Go to https://desktop.github.com
- Download and install GitHub Desktop for your OS
- Open GitHub Desktop and sign in with your GitHub account
- You’re all set — we’ll walk through using it together in class
5 Course Textbooks
We’ll draw from two excellent, freely available online books throughout this course. Bookmark both now.
5.1 R for Data Science (2nd Edition)
Hadley Wickham, Mine Çetinkaya-Rundel & Garrett Grolemund
The go-to introduction to doing data science in R using the tidyverse. Covers data import, tidying, visualization, and more.
5.2 Advanced R (2nd Edition)
Hadley Wickham
A deeper dive into how R works under the hood, functions, environments, object-oriented programming, and performance. We’ll reference this later in the course.
6 Helpful Resources
Not sure where to begin with Git or R? These beginner-friendly resources will help you feel more comfortable before we dive in.
6.1 GitHub: Cloning a Repository
Once you have GitHub Desktop set up, one of the first things you’ll do is clone a repository (that means downloading a copy of a project from GitHub to your computer). The official GitHub docs walk you through exactly how to do this:
6.2 Beginner Video Tutorials
Sometimes it’s easier to watch someone do it first. Here are a few videos to get you oriented:
Git and GitHub for Beginners. A great overview of Git concepts and how to use GitHub, covers the core ideas you’ll need for this course.
Learn R in 39 Minutes Video. A great overview of downloading and using R.
R Programming for Beginners. A beginner, follow-along lesson great for learning basics!
7 Quick Checklist
Before our first class, make sure you have:
See you on Day 1!