R-Carpentry

Caltech Library R Carpentry Workshops


Description:

This repository contains lesson plans for Caltech Library-facilitated R Carpentry workshops. Workshops are organized in subfolders by date of workshop.

Folders named with only the date are basic R Carpentry workshops. Advanced R topics have both date and topic in the folder name. Each subfolder contains all of the necessary files for that workshop.

Please see files in the workshop folders, specifically the README, for more information on any particular workshop.


Required Computer Setup

Up to Date for the 2022-02 Workshops

The Carpentries’ teaching is hands-on, so participants are encouraged to use their own computers to insure the proper setup of tools for an efficient workflow. These lessons assume prior knowledge of RStudio and R. Working through this lesson requires working copies of the software described below. To most effectively use these materials, please make sure to install everything before working through this lesson.

R and RStudio are separate downloads and installations. R is the underlying statistical computing environment. RStudio is a graphical integrated development environment (IDE) that makes using R easier and more interactive. You need to install R before you install RStudio.

If you don’t have R and RStudio installed:

  1. Download R Version 4.1.2 from the CRAN website for your operating system:
    • Windows
    • Mac OS
    • Linux (Information provided to get the most recent version of R for common distributions.)
  2. Open the .exe (Windows) or .pkg (Mac) just downloaded to install R. For Linux, follow the directions given on the website for your particular distribution.
    • If you are a Mac user, it is also a good idea to install XQuartz (needed by some R packages).
  3. Go to the RStudio download page and download the latest version of RStudio for your platform (RStudio Desktop 2021.09.0+351).

  4. Open the downloaded file and install RStudio.

  5. Once it’s installed, open RStudio to make sure it works and you don’t get any error messages, and the Console window shows the correct version of R installed.

If you already have R and RStudio installed:

  1. Open RStudio, and click on “Help” > “Check for updates”. If a new version is available, quit RStudio, and download the latest version of RStudio from the RStudio download page.

  2. To check which version of R you are using, start RStudio and check the Console window. The first line that appears in the Console indicates the version of R that is running. Alternatively, you can type sessionInfo(), which will also display which version of R is running.

  3. If you are not running R version 4.1.2, please see Steps 1 and 2 above under “If you don’t have R and RStudio installed”.

    • You can check here for more information on how to remove old versions from your system if you wish to do so.

Required Files

Please see the individual workshop README file for the required files for each workshop.


Resources

The Caltech Library has many books and ebooks on R, including many on the Safari platform (link requires Caltech credentials to view).

Page last updated 2022-01-26