datacarpentry / R-ecology-lesson

Data Analysis and Visualization in R for Ecologists
https://datacarpentry.org/R-ecology-lesson/
Other
314 stars 508 forks source link

tidyr - pivot_ instead of gather & spread #684

Closed MonkmanMH closed 2 years ago

MonkmanMH commented 3 years ago

Responding to Issues #580 and #676

This pull request changes the text and code of the "Manipulating data" lesson to incorporate the functions pivot_longer and pivot_wider, introduced with {tidyr} 1.0.0, instead of the retired functions gather and spread.

The content also harmonizes with the approach in the R for Social Sciences lesson, "Data Wrangling with dplyr and tidyr" https://datacarpentry.org/r-socialsci/03-dplyr-tidyr/index.html

bvreede commented 3 years ago

Oh and in addition, perhaps the old gather/spread images should be deleted?

MonkmanMH commented 3 years ago

@bvreede -- thanks for the feedback. It may take me a few days to review them (deep in end-of-term marking!), but at first glance this is valuable.

MonkmanMH commented 2 years ago

Closed, as this pull request was superceded by @njlyon0's efforts in pull request #809 (which incorporates much of what was here).