Online Data Carpentry Workshop

AA TVET

02 - 06 November, 2020

11:00 am - 14:00 pm EAT / 09:00 am - 12:00 am WAT

Instructors: Mr. Yonas Demissew, Ms. Bonny Adane

Helpers: Dr. Margareth Gfrerer

General Information

Data Carpentry develops and teaches workshops on the fundamental data skills needed to conduct research. Its target audience is researchers who have little to no prior computational experience, and its lessons are domain specific, building on learners' existing knowledge to enable them to quickly apply skills learned to their own research. Participants will be encouraged to help one another and to apply what they have learned to their own research problems.

For more information on what we teach and why, please see our paper "Good Enough Practices for Scientific Computing".

Who: The course is aimed at graduate students and other researchers. You don't need to have any previous knowledge of the tools that will be presented at the workshop.

Where: This is an online event.

When: 02 - 06 November, 2020. Add to your Google Calendar.

Requirements: Be a postgraduate student in the Humanities and Social Sciences. Participants must have access to a laptop with a Mac, Linux, or Windows operating system (not a tablet, Chromebook, etc.) that they have administrative privileges on. Some sponsorship is available to access mobile data - please contact the organisers for more information. They should have a few specific software packages installed. Since this is an online workshop, participants need to have access to internet (listed below).

Accessibility: We are committed to making this workshop accessible as far as possible. Please make sure that you have the following:

Materials will be provided in advance of the workshop and you will be able to ask the organisers for extra materials if needed in advance. If we can help making learning easier for you.

Contact: Please email carpentry.ethiopia@gmail.com for more information.


Code of Conduct

Everyone who participates in Carpentries activities is required to conform to the Code of Conduct.This document also outlines how to report an incident if needed.


Surveys

Please be sure to complete these surveys before and after the workshop.

Pre-workshop Survey

Post-workshop Survey


Schedule

Day 2

11:00-12:30 Introduction to R
12:30-14:00 Introduction to R
14:00 END

Day 3

11:00-12:30 Introduction to R
12:30-14:00 Introduction to R
END

Syllabus


Setup

To participate in a Data Carpentry workshop, you will need access to the software described below. In addition, you will need an up-to-date web browser.

We maintain a list of common issues that occur during installation as a reference for instructors that may be useful on the Configuration Problems and Solutions wiki page.

The setup instructions for the Data Carpentry Ecology workshops (with R) can be found at the workshop overview site.

Additional R setup information is below.

### 1: R and RStudio * R and RStudio are separate downloads and installations. R is the underlying statistical computing environment, but using R alone is no fun. RStudio is a graphical integrated development environment (IDE) that makes using R much easier and more interactive. You need to install R before you install RStudio. After installing both programs, you will need to install some specific R packages within RStudio. Follow the instructions below for your operating system, and then follow the instructions to install **`tidyverse`**. For this version we recommend at least R version 4.0 or later and RStudio 1.2 #### Windows > ## If you already have R and RStudio installed > > * Open RStudio, and click on "Help" > "Check for updates". If a new version is > available, quit RStudio, and download the latest version for RStudio. > * To check which version of R you are using, start RStudio and the first thing > that appears in the console indicates the version of R you are > running. Alternatively, you can type `sessionInfo()`, which will also display > which version of R you are running. Go on > the [CRAN website](https://cran.r-project.org/bin/windows/base/) and check > whether a more recent version is available. If so, please download and install > it. You can [check here](https://cran.r-project.org/bin/windows/base/rw-FAQ.html#How-do-I-UNinstall-R_003f) for > more information on how to remove old versions from your system if you wish to do so. {: .solution} > ## If you don't have R and RStudio installed > > * Download R from > the [CRAN website](https://cran.r-project.org/bin/windows/base/release.htm). > * Run the `.exe` file that was just downloaded > * Go to the [RStudio download page](https://www.rstudio.com/products/rstudio/download/#download) > * Under *Installers* select **RStudio x.yy.zzz - Windows Vista/7/8/10** (where x, y, and z represent version numbers) > * Double click the file to install it > * Once it's installed, open RStudio to make sure it works and you don't get any > error messages. {: .solution} #### macOS > ## If you already have R and RStudio installed > > * Open RStudio, and click on "Help" > "Check for updates". If a new version is > available, quit RStudio, and download the latest version for RStudio. > * To check the version of R you are using, start RStudio and the first thing > that appears on the terminal indicates the version of R you are running. Alternatively, you can type `sessionInfo()`, which will > also display which version of R you are running. Go on > the [CRAN website](https://cran.r-project.org/bin/macosx/) and check > whether a more recent version is available. If so, please download and install > it. In any case, make sure you have at least R 4.0. {: .solution} > ## If you don't have R and RStudio installed > > * Download R from > the [CRAN website](https://cran.r-project.org/bin/macosx/). > * Select the `.pkg` file for the latest R version > * Double click on the downloaded file to install R > * It is also a good idea to install [XQuartz](https://www.xquartz.org/) (needed > by some packages) > * Go to the [RStudio download page](https://www.rstudio.com/products/rstudio/download/#download) > * Under *Installers* select **RStudio x.yy.zzz - Mac OS X 10.6+ (64-bit)** > (where x, y, and z represent version numbers) > * Double click the file to install RStudio > * Once it's installed, open RStudio to make sure it works and you don't get any > error messages. {: .solution} #### Linux > ## Follow the instructions for your distribution > > from [CRAN](https://cloud.r-project.org/bin/linux), they provide information > to get the most recent version of R for common distributions. For most > distributions, you could use your package manager (e.g., for Debian/Ubuntu run > `sudo apt-get install r-base`, and for Fedora `sudo yum install R`), but we > don't recommend this approach as the versions provided by this are > usually out of date. In any case, make sure you have at least R 3.2. > * Go to the [RStudio download page](https://www.rstudio.com/products/rstudio/download/#download) > * Under *Installers* select the version that matches your distribution, and > install it with your preferred method (e.g., with Debian/Ubuntu `sudo dpkg -i > rstudio-x.yy.zzz-amd64.deb` at the terminal). > * Once it's installed, open RStudio to make sure it works and you don't get any > error messages. {: .solution} ### 2: Install the Tidyverse * After installing R and RStudio, you need to install the `tidyverse` packages. Start RStudio by double-clicking the icon and then type: `install.packages("tidyverse")`. You can also do this by going to Tools -> Install Packages and typing the names of the package you want to install. You will see that the name auto-completes. Make sure the 'inclde dependencies' box is checked. ![RStudio 'install packages' screen.](https://ucsbcarpentry.github.io/2020-08-17-Summer-R/fig/install_packages.png) ### 3: Test your installation * Download this [test R script](https://ucsbcarpentry.github.io/2020-08-17-Summer-R/data/test.r) * Open R Studio and use the File menu to open the script. (This script will load the Tidyverse and a package of data that is build in to base R.) * By default, the script pane will open on the upper left. Select all 9 lines of the script. * Click 'Run the current line or selection' button ![RStudio screen after running test script.](https://ucsbcarpentry.github.io/2020-08-17-Summer-R/fig/run.png) * You should see a graph that looks like the illustration in the lower right pane ![RStudio screen after running test script.](https://ucsbcarpentry.github.io/2020-08-17-Summer-R/fig/diamonds.png)