1. Learn
  2. /
  3. Courses
  4. /
  5. Helsinki Open Data Science

Connected

Exercise

Individuals on the plot

Graphical displays of data are almost always useful for exposing patterns in the data, particularly when these are unexpected; this might be of great help in suggesting which class of models might be most sensibly applied in the later more formal analysis.

To begin we shall plot the BPRS values for all 40 men, differentiating between the treatment groups into which the men have been randomized. This simple graph makes a number of features of the data readily apparent.

REMEMBER: In ggplot2 or dplyr syntax, you generally do not need to "quote" variable names!

Instructions

100 XP
  • Draw the plot with week on the x-axis and bprs on the y-axis
  • Inspect the plot. See how both the BPRS-score and the variability between individuals decrease over the eight weeks time