Suggested edits for tidy-data chapter (#1016)

* replace even with ever
* use correct variable name in prose
This commit is contained in:
Adam Gruer
2022-05-05 22:53:19 +10:00
committed by GitHub
parent 3619b8a41b
commit fa0851341f

View File

@@ -566,7 +566,7 @@ It's then up to you to figure out what's gone wrong with your data and either re
While `pivot_wider()` is occasionally useful for making tidy data, its real strength is making **untidy** data.
While that sounds like a bad thing, untidy isn't a pejorative term: there are many untidy data structures that are extremely useful.
Tidy data is a great starting point for most analyses but it's not the only data format you'll even need.
Tidy data is a great starting point for most analyses but it's not the only data format you'll ever need.
The following sections will show a few examples of `pivot_wider()` making usefully untidy data for presenting data to other humans, for input to multivariate statistics algorithms, and for pragmatically solving data manipulation challenges.
@@ -622,7 +622,7 @@ col_year
`pivot_wider()` produces a tibble where each row is labelled by the `country` variable.
But most classic statistical algorithm don't want the identifier as an explicit variable; they want as a **row name**.
We can turn the `year` variable into row names with `column_to_rowname()`:
We can turn the `country` variable into row names with `column_to_rowname()`:
```{r}
col_year <- col_year |>