-
Notifications
You must be signed in to change notification settings - Fork 48
/
index.Rmd
125 lines (96 loc) · 8.12 KB
/
index.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
---
title: "R for Excel Users"
author: "Julie Lowndes & Allison Horst"
date: "`r Sys.Date()`"
site: bookdown::bookdown_site
documentclass: book
bibliography: [book.bib, packages.bib]
biblio-style: apalike
link-citations: yes
description: "This is a workshop for RStudio::conf(2020) in San Francisco, California"
---
# Welcome {#welcome}
Hello! This is a course taught by Dr. Julie Stewart Lowndes and Dr. Allison Horst at the RStudio Conference: January 27-28 in San Francisco, California.
```{r, echo=FALSE, out.width="100%"}
knitr::include_graphics("img/r-for-excel-monsters.jpg")
```
This course is for Excel users who want to add or integrate R and RStudio into their existing data analysis toolkit. It is a friendly intro to becoming a modern R user, full of tidyverse, RMarkdown, GitHub, collaboration & reproducibility.
This book is written to be used as a reference, to teach, or as self-paced learning. And also, awesomely, it’s created with the same tools and practices we will be talking about: R and RStudio — specifically [bookdown](https://bookdown.org/yihui/bookdown/) — and GitHub. It is being fine-tuned but the most recent version is always available:
**This book**: <https://rstudio-conf-2020.github.io/r-for-excel/>
**Book GitHub repo**: <https://github.com/rstudio-conf-2020/r-for-excel>
**Accompanying slides**: [Google Slides](https://docs.google.com/presentation/d/1w9cVzEsdbyZ6vay4UnoTvTWd9t-AO_x06HoVzgAiSFE/edit?usp=sharing)
**Blog**: <https://education.rstudio.com/blog/2020/02/conf20-r-excel/>
---
**About us**
We are environmental scientists who use and teach R in our daily work. We both work at the University of California Santa Barbara, USA.
[Julie Lowndes](https://jules32.github.io) is a Senior Fellow and Director of Openscapes at the National Center for Ecological Analysis and Synthesis.
[Allison Horst](https://allisonhorst.github.io) is a Lecturer of Data Science & Statistics at the Bren School of Environmental Science and Management. She is also Artist in Residence at RStudio!
---
<!----
Participants will get hands-on experience working with data across R and Excel, focusing on: data import and export, basic wrangling, visualization, and reporting with RMarkdown. Throughout, we will emphasize conventions and best practices for working reproducibly and collaboratively with data, including naming conventions, documentation, organization, all while “keeping the raw data raw”. Whether you are working in Excel and want to get started in R, already working in R and want tools for working more seamlessly with collaborators who use Excel, or whether you are new to data analysis entirely, this is the course for you!
If you answer yes to these questions, this course is for you!
- Are you an Excel user who wants to expand your data analysis toolset with R?
- Do you want to bridge analyses between Excel and R, whether working independently or to more easily collaborate with others who use Excel or R?
- Are you new to data analysis, and looking for a good place to get started?
--->
<!--- This is going to be fun, because learning R (and friends) is empowering! This training book is written (and always improving) so you can use it as self-paced learning, or it can be used to teach an in-person workshop where the instructor live-codes. Either way, you should do everything hands-on on your own computer as you learn.
Before you begin, be sure you are all set up: see the prerequisites in Chapter \@ref(overview). --->
## Agenda
|Time | Day 1| Day 2|
|:----------|----------:|----------:|
|9-10:30 | [Overview](#overview), [R & RStudio, RMarkdown](#rstudio) (JL) | [Tidying](#tidying) (AH) |
|break | | |
|11-12:30 | [Intro to GitHub](#github) (JL) | [Filters & joins](#filter-join) (AH) |
|lunch | ||
|13:30-15:00 | [Graphs with `ggplot2`](#ggplot2) (AH) | [Collaborating & getting help](#collaborating) (JL) |
|break | | |
|15:30-17:00 | [Pivot Tables & `dplyr`](#pivot-tables) (JL) | [Synthesis](#synthesis) (AH) |
## Prerequisites
Before the training, please do the following (20 minutes). All software is free.
1. **Download and install R and RStudio**
- R: <https://cloud.r-project.org/>
- RStudio: <http://www.rstudio.com/download>
- Follow your operating system's normal installation process
1. **Create a GitHub account**
- GitHub: <https://github.com>
- Follow optional [advice on choosing your username](https://happygitwithr.com/github-acct.html)
- Remember your username, email and password; we will need them for the workshop!
1. **Download and install Git**
- Git: <https://git-scm.com/downloads>
- Follow your operating system's normal installation process. Note: you will not see an application called Git listed but if the installation process completed it was likely successful, and we will confirm together
1. **Download workshop data**
- Google Drive folder: [r-for-excel-data ](https://drive.google.com/drive/folders/1RywSUw8hxETlROdIhLIntxPsZq0tKSdS?usp=sharing)
- Save it temporarily somewhere you will remember; we will move it together
<!---
1. Get comfortable: if you're not in a physical workshop, be set up with two screens if possible. You will be following along in RStudio on your own computer while also watching a virtual training or following this tutorial on your own.
--->
## Data citations
We use the following data from the Santa Barbara Coastal Term Ecological Research and National Oceanic and Atmospheric Administration in this workshop:
- **fish.csv**
- Description: Reef fish abundance, SB coast
- Link: https://portal.edirepository.org/nis/mapbrowse?scope=knb-lter-sbc&identifier=17&revision=newest
- Citation: Reed D. 2018. SBC LTER: Reef: Kelp Forest Community Dynamics: Fish abundance. Environmental Data Initiative. [doi](https://doi.org/10.6073/pasta/dbd1d5f0b225d903371ce89b09ee7379).
- **inverts.xlsx**
- Description: Invertebrate counts, SB coast
- Link: https://portal.edirepository.org/nis/mapbrowse?scope=knb-lter-sbc&identifier=19&revision=newest
- Citation: Reed D. 2018. SBC LTER: Reef: Kelp Forest Community Dynamics: Invertebrate and algal density. Environmental Data Initiative. [doi](https://doi.org/10.6073/pasta/748ee568669ca2b740e9b8f5f8a085d8).
- **kelp.xlsx**
- Description: Giant kelp abundance and size, SB coast
- Link: https://portal.edirepository.org/nis/mapbrowse?scope=knb-lter-sbc&identifier=18&revision=newest
- Citation: Reed D. 2018. SBC LTER: Reef: Kelp Forest Community Dynamics: Abundance and size of Giant Kelp (Macrocystis Pyrifera), ongoing since 2000. Environmental Data Initiative. [doi](https://doi.org/10.6073/pasta/dea56e02127161194626f97c8b6118e8).
- **lobsters.xlsx and lobsters2.xlsx**
- Description: Lobster size, abundance and fishing pressure (SB coast)
- Link: https://portal.edirepository.org/nis/mapbrowse?scope=knb-lter-sbc&identifier=77&revision=newest
- Citation: Reed D. 2019. SBC LTER: Reef: Abundance, size and fishing effort for California Spiny Lobster (Panulirus interruptus), ongoing since 2012. Environmental Data Initiative. [doi](https://doi.org/10.6073/pasta/a593a675d644fdefb736750b291579a0).
- **noaa_fisheries.csv**
- Description: NOAA Commercial Fisheries Landing data (1950 - 2017)
- Link: https://www.st.nmfs.noaa.gov/commercial-fisheries/commercial-landings/
- Source: Fisheries Statistics Division of the NOAA Fisheries
- **substrate.xlsx **
- Description: Algal cover, invertebrates and substrates near Santa Cruz Island
- Link: https://portal.edirepository.org/nis/mapbrowse?scope=knb-lter-sbc&identifier=38&revision=newest
- Citation: Schmitt R. J., S. J. Holbrook. 2012. SBC LTER: Santa Cruz Island: Cover of Algae, Invertebrates and Benthic Substrate. Environmental Data Initiative. [doi](https://doi.org/10.6073/pasta/9ce22c5b70d3e6ef8f0445e6cf782f87).
- **ca_np.csv and ci_np.xlsx**
- Description: US National Parks visitation data (1904 - 2016)
- Link: https://data.world/inform8n/us-national-parks-visitation-1904-2016-with-boundaries
- Source: Data originally accessed from the US Department of the Interior National Park Service’s Integrated Resource Management Applications data portal (https://irma.nps.gov/)