FES 720 Introduction to R

LAB: Plotting Data

This is the lab associated with the lecture and lesson on Plotting Data in R.

Please upload your final completed lab on the Assignments page in Canvas, as per the instructions below.

You are welcome and expected to ask for help from the instructors if you get stuck: Please also come to the R Bootcamp on Friday—there is coffee and snacks!


Using the New Haven Road Race data…

dat <- read.table('http://www.simonqueenborough.info/R/data/race-data-full.txt', header = TRUE, sep  = '\t')
dat <- na.omit(dat) 
dat2 <- droplevels(dat)

1. Make a plot of the number of runners in each age class.

The plot should include:

2. Plot each runner’s pace (y) as a function of their sex (x).

The plot should include:

3. Plot each runner’s pace as a function of their age class.

The plot should include:

4. Plot each runner’s net time as a function of their pace.

The plot should have:


How to write up your answers

Please check the help page for a reminder, if you need to.


Updated: 2017-10-30