C4 - Instructions

Instructions for chapter 4: “Data Visualization”

Introduction

In this chapter you will learn how to create plots with the ggplot2 package (part of the tidyverse).

To meet this chapter’s learning objectives, please complete the respective exercise sheet. The instructions below will guide you through the process of solving the exercise sheet.

Getting ready

Step 1

Briefly check out the exercise sheet for chapter 4 to get an impression of what you need to learn/know to solve it.

Step 2

Solve Tasks 1-7 of the exercise sheet.

Step 3

Watch the following YouTube Video: An Introduction to Data Visualization

Step 4

  1. Do the “Exploratory Data Analysis” tutorial: Exploratory Data Analysis

  2. Read the “Exploratory Data Analysis” chapter of the R4DS book: Exploratory Data Analysis

Solve task 8 of the exercise sheet.

Bar charts

Step 5

  1. Read the following introduction to bar plots: Bar Charts

  2. Do the “Bar Charts” tutorial: Bar Charts

Comment: It is sufficient if you focus on the subchapters “Bar Charts” and “Aesthetics”.

Solve tasks 9-10 of the exercise sheet.

Histograms

Step 6

  1. Read the following introduction to bar plots: Histogramms

  2. Do the “Histograms” tutorial: Histograms

Comment: It is sufficient to focus on the subchapter “Histograms”.

Solve tasks 11-12 of the exercise sheet.

Denistiy Plots

Step 7

Watch the following Video: Density Plots

Solve tasks 13-14.

Boxplots

Step 11

Watch the following Video: Boxplots

Solve task 15.

Scatterplots

Step 12

Watch the following Video: Scatter Plots

Solve task 16.

Step 13

Watch the following Video: Smoother

Solve task 17.

Step 14

Watch the following Video: Draw Lines

Solve Task 18.

Step 15

Compare your solutions to the sample solution for exercise sheet 4.

Additional Resources

Cheat Sheet: Data Visualization -> Nice overview on how to make plots with ggplot2

If you want to make your graphs more beautiful and understandable (e.g add a title, change colours), the following resources are recommended: