From ad7fb0dd4bb900b64369db8ea5e226e6a9bb240c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mine=20=C3=87etinkaya-Rundel?= Date: Wed, 3 Mar 2021 17:13:14 +0000 Subject: [PATCH] Second crack and 2e structure --- _bookdown.yml | 17 ++++++++++------- data-types.Rmd | 29 +++++++++++++++++++++++++++++ index.Rmd | 2 +- logicals-numbers.Rmd | 3 +++ missing-values.Rmd | 3 +++ rectangle.Rmd | 2 +- row-wise.Rmd | 16 ---------------- vector-tools.Rmd | 3 +++ whole-game.Rmd | 3 +++ 9 files changed, 53 insertions(+), 25 deletions(-) create mode 100644 data-types.Rmd create mode 100644 logicals-numbers.Rmd create mode 100644 missing-values.Rmd delete mode 100644 row-wise.Rmd create mode 100644 vector-tools.Rmd diff --git a/_bookdown.yml b/_bookdown.yml index 062f6af..250bab6 100644 --- a/_bookdown.yml +++ b/_bookdown.yml @@ -11,24 +11,27 @@ rmd_files: [ "data-visualize.Rmd", "workflow-basics.Rmd", "data-transform.Rmd", - "data-import.Rmd", "data-tidy.Rmd", + "data-import.Rmd", "workflow-scripts.Rmd", "EDA.Rmd", "workflow-projects.Rmd", - "wrangle.Rmd", + "data-types.Rmd", "tibble.Rmd", - "tidy.Rmd", - "rectangle.Rmd", "relational-data.Rmd", - "list-columns.Rmd", - "column-wise.Rmd", - "row-wise.Rmd", + "logicals-numbers.Rmd", + "vector-tools.Rmd", + "missing-values.Rmd", "strings.Rmd", "factors.Rmd", "datetimes.Rmd", + "wrangle.Rmd", + "column-wise.Rmd", + "list-columns.Rmd", + "rectangle.Rmd", + "import.Rmd", "import-rectangular.Rmd", "import-spreadsheets.Rmd", diff --git a/data-types.Rmd b/data-types.Rmd new file mode 100644 index 0000000..a465654 --- /dev/null +++ b/data-types.Rmd @@ -0,0 +1,29 @@ +# (PART) Data types {.unnumbered} + +# Introduction {#data-types-intro} + +In this part of the book, you'll learn about data types, ... + + + +This part of the book proceeds as follows: + +- In Chapter \@ref(tibbles), you'll learn about the variant of the data frame that we use in this book: the **tibble**. You'll learn what makes them different from regular data frames, and how you can construct them "by hand". + +Data wrangling also encompasses data transformation, which you've already learned a little about. +Now we'll focus on new skills for specific types of data you will frequently encounter in practice: + +- Chapter \@ref(relational-data) will give you tools for working with multiple interrelated datasets. + + + + + + + +- Chapter \@ref(strings) will give you tools for working with strings and introduce regular expressions, a powerful tool for manipulating strings. + +- Chapter \@ref(factors) will introduce factors -- how R stores categorical data. + They are used when a variable has a fixed set of possible values, or when you want to use a non-alphabetical ordering of a string. + +- Chapter \@ref(dates-and-times) will give you the key tools for working with dates and date-times. diff --git a/index.Rmd b/index.Rmd index 7d5d962..739b8cc 100644 --- a/index.Rmd +++ b/index.Rmd @@ -13,7 +13,7 @@ documentclass: book # Welcome {.unnumbered} -Buy from amazon This is the website for the work-in-progress 2nd edition of **"R for Data Science"**. This book will teach you how to do data science with R: You'll learn how to get your data into R, get it into the most useful structure, transform it, visualise it and model it. +[![Buy from amazon](cover.png){.cover width="250"}](http://amzn.to/2aHLAQ1) This is the website for the work-in-progress 2nd edition of **"R for Data Science"**. This book will teach you how to do data science with R: You'll learn how to get your data into R, get it into the most useful structure, transform it, visualise it and model it. In this book, you will find a practicum of skills for data science. Just as a chemist learns how to clean test tubes and stock a lab, you'll learn how to clean data and draw plots---and many other things besides. These are the skills that allow data science to happen, and here you will find the best practices for doing each of these things with R. diff --git a/logicals-numbers.Rmd b/logicals-numbers.Rmd new file mode 100644 index 0000000..656a8c8 --- /dev/null +++ b/logicals-numbers.Rmd @@ -0,0 +1,3 @@ +# Logicals and numbers + +## Introduction diff --git a/missing-values.Rmd b/missing-values.Rmd new file mode 100644 index 0000000..f08b770 --- /dev/null +++ b/missing-values.Rmd @@ -0,0 +1,3 @@ +# Missing values + +## Introduction diff --git a/rectangle.Rmd b/rectangle.Rmd index 53624ca..b999fed 100644 --- a/rectangle.Rmd +++ b/rectangle.Rmd @@ -1,4 +1,4 @@ -# Rectangle data +# Rectangling data ## Introduction diff --git a/row-wise.Rmd b/row-wise.Rmd deleted file mode 100644 index 8c76617..0000000 --- a/row-wise.Rmd +++ /dev/null @@ -1,16 +0,0 @@ -# Row-wise operations - -## Introduction - - - -### Prerequisites - -In this chapter we'll continue using dplyr. -dplyr is a member of the core tidyverse. - -```{r setup, message = FALSE} -library(tidyverse) -``` - - diff --git a/vector-tools.Rmd b/vector-tools.Rmd new file mode 100644 index 0000000..463ef46 --- /dev/null +++ b/vector-tools.Rmd @@ -0,0 +1,3 @@ +# General vector tools + +## Introduction diff --git a/whole-game.Rmd b/whole-game.Rmd index 6cbc884..7174cf4 100644 --- a/whole-game.Rmd +++ b/whole-game.Rmd @@ -17,6 +17,9 @@ In this part of the book you will learn some useful tools that have an immediate - Visualisation alone is typically not enough, so in Chapter \@ref(data-transform) you'll learn the key verbs that allow you to select important variables, filter out key observations, create new variables, and compute summaries. +- In Chapter \@ref(data-tidy), you'll learn about tidy data, a consistent way of storing your data that makes transformation, visualisation, and modelling easier. + You'll learn the underlying principles, and how to get your data into a tidy form. + - Before you can transform and visualise your data, you need to first get your data into R. In Chapter \@ref(data-import) you'll learn the basics of getting plain-text rectangular data into R.