Choose Your Path

Where to begin with the workbook

Choose a starting point based on your experience with R and RStudio.

You can use this workbook even if you have never written code. Choose the path below that best describes your experience.

If R Is New To You

Complete the Start Here pages in order:

  1. Set Up RStudio.
  2. Run Your First Script.
  3. Understanding EAMMi2.
  4. Begin Chapter 1.

The first chapters provide complete code and explain new commands when they first matter. Focus on understanding the purpose of each step. Memorization can come later through practice.

If You Have Used R Before

You may begin with Chapter 1 after you:

  1. download and unzip the starter files;
  2. open exploring-statistics-r.Rproj in RStudio; and
  3. run scripts/00-open-and-check-data.R to confirm that the data open correctly.

Review Run Your First Script if the project, script, or Console workflow differs from the way you usually work.

What Everyone Needs

Download the starter files. The folder includes:

  • exploring-statistics-r.Rproj, which opens the workbook project;
  • data/EAMMi2-REDUCED.csv, which contains the teaching data;
  • scripts/_setup.R, which prepares the R tools and data used by the chapter scripts;
  • scripts/00-open-and-check-data.R, which checks the starter setup;
  • one R script for each workbook chapter; and
  • survey documentation in the resources folder.
ImportantKeep the folder together

After unzipping the starter files, do not move the project file, data folder, or scripts folder away from one another. The chapter scripts use their locations inside this folder to find the data.

A Useful Learning Routine

When you reach a code example:

  1. Read the sentence above the code.
  2. Predict what the code should produce.
  3. Run the code in the chapter script.
  4. Find the result in RStudio.
  5. Check whether the result is reasonable.
  6. Explain what the result means for the research question.

Small mistakes are a normal part of learning R. The Troubleshooting page explains common messages and how to recover from them.