Initial Setup

I will help you with setting up R and RStudio as needed and we will discuss installation in class, but here are the basic links to resources you will need to get started. Posit Cloud is another way to use R and RStudio without local installation, but for this course it is a temporary/short-term option.

Install R 4.4.1

Everyone should install R version 4.4.1. The first step is to download the latest “base” version for your computer:

After downloading, you will need to follow the usual software install steps for your operating system.

Install RStudio

Download the free “RStudio Desktop” installer based on your operating system from the list on this page: https://posit.co/download/rstudio-desktop/#download

Install according to your operating system.

RStudio Settings

There are some important options to change to establish a good working environment. Go to Global Options... under the Tools menu, and in the General tab, uncheck the box that says Restore .RData into workspace at startup. This makes sure you are starting with a clean workspace each time.

Also change the option to save your workspace data when you exit to Never for the same reason. The only thing you want to save are your scripts.

RStudio General Settings

RStudio General Settings

You may also want to change the appearance of your code to make it easier for you to read. You can change the theme for different background and text colors, and the font and font size used for code.

RStudio Appearance Settings

RStudio Appearance Settings

Additional R Setup

You probably will not need these immediately, but the following will help with installing and using some other packages/tools in R.

Windows: install the “release” version installer for Rtools.

MacOS: install XQuartz for some visualization tools. You will also need to install Xcode to install packages that required compilation. You can install it directly from the App Store.