Lesson 1 of 3

Univariate EDA

You can now get data into R, tidy it, and join tables together. So you are holding a clean data frame. The very next question, before any model or fancy chart, is the simplest one there is: what is actually in it?

Meet Maya, who runs a small neighbourhood bakery. She has just handed you one column: her daily revenue for the 30 days of March, in dollars. Below is every one of those 30 days drawn as a histogram. By the end of this lesson you will read a picture like this at a glance, and back it up with numbers.

By the end you will be able to:

  • Follow a repeatable 7-step framework for exploring any new dataset
  • Read one variable's distribution from a histogram: its shape, its typical value, and any surprises
  • Summarise that variable with the right numbers (mean, median, spread) and a boxplot

Prerequisites: you can run R and load a package with library(), and you have a tidy data frame in hand (the dplyr and joins courses got you here). Every other term is defined as it appears.

The map

EDA is a disciplined first look

Exploratory Data Analysis (EDA) is the work of getting to know a dataset before you commit to any conclusion. Its goal is to describe and question, not to confirm. You are not trying to prove Maya's bakery is doing well; you are trying to see, honestly, what the numbers say, including the parts that surprise you.

It helps to follow the same path every time. Here is a 7-step framework you can run on any new dataset:

Note
This lesson lives at step 4, one variable at a time, which is where real understanding starts. Step 5 (two variables and correlation) and step 6 (outliers, at scale) are the next two lessons in this course. You already met steps 2 and 3 in the import and tidy lessons.