Chapter 5. Exploratory Data Analysis
Introduction
This chapter will show you how to use visualization and transformation to explore your data in a systematic way, a task that statisticians call exploratory data analysis, or EDA for short. EDA is an iterative cycle. You:
-
Generate questions about your data.
-
Search for answers by visualizing, transforming, and modeling your data.
-
Use what you learn to refine your questions and/or generate new questions.
EDA is not a formal process with a strict set of rules. More than anything, EDA is a state of mind. During the initial phases of EDA you should feel free to investigate every idea that occurs to you. Some of these ideas will pan out, and some will be dead ends. As your exploration continues, you will hone in on a few particularly productive areas that youâll eventually write up and communicate to others.
EDA is an important part of any data analysis, even if the questions are handed to you on a platter, because you always need to investigate the quality of your data. Data cleaning is just one application of EDA: you ask questions about whether or not your data meets your expectations. To do data cleaning, youâll need to deploy all the tools of EDA: visualization, transformation, and modeling.
Prerequisites
In this chapter weâll combine what youâve learned about dplyr and ggplot2 to interactively ask questions, answer them with data, and then ask new questions.
library
(
tidyverse
)
Questions
There are no routine ...
Get R for Data Science now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.