Data Analysis and Visualization with R

May 23-27,2022

9:00 am - 5:00 pm

Instructors: Mesfin Diro

Helpers: TBA

General Information

This Training Workshop aims to help researchers get their work done in less time and with less pain by teaching them basic research computing skills. This hands-on workshop will cover basic concepts and tools, including data management, data cleaning , Data analysis and Report Writing. 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 "Best Practices for Scientific Computing".

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

Where: Madda Walabu University. Get directions with OpenStreetMap or Google Maps.

When: May 23-27,2022. Add to your Google Calendar.

Requirements: Participants must bring a laptop with a Mac, Linux, or Windows operating system (not a tablet, Chromebook, etc.) that they have administrative privileges on. They should have a few specific software packages installed (listed below).

Contact: Please email mesfin.diro@aau.edu.et for more information.


Schedule

Day 1

09:00 Data Organization in Spreadsheets
10:30 Coffee
11:00 Spreadsheets(Continued)
12:00 Lunch break
13:00 Data Cleaning in OpenRefine
14:30 Coffee
15:00 OpenRefine(Continued)
16:00 Wrap-up

Day 2

09:00 Introduction to R
10:30 Coffee
11:00 R(continued): Starting with data
12:00 Lunch break
13:00 R(continued):Aggregating and analyzing data
14:30 Coffee
15:00 R(continued): Aggregating and analyzing data
16:00 Wrap-up

Day 3

09:00 R(continued): Data Visualization
10:30 Coffee
11:00 R(continued): Data Visualization
12:00 Lunch break
13:00 Rmarkdown
14:30 Coffee
15:00 Rmarkdown(continued)
16:00 Wrap-up

Day 4

09:00 Advanced Data Analysis
10:30 Coffee
11:00 Advanced Data(continued)
12:00 Lunch break
13:00 Advanced Data(continued)
14:30 Coffee
15:00 Advanced Data(continued)
16:00 Wrap-up

Day 5

09:00 Manuscript Preparation with RMarkdown
10:30 Coffee
11:00 RMarkdown(continued)
12:00 Lunch break
13:00 RMarkdown(continued)
14:30 Coffee
15:00 Rmarkdown(continued)
16:00 Wrap-up

We will use this collaborative document for chatting, taking notes, and sharing URLs and bits of code.


Syllabus

Data Organization with Spreadsheet

  • Introduction to spreadsheet
  • formating Data Tables
  • Formating Problems
  • Dates as data
  • Quality Control
  • Export data
  • Reference...

Data Cleaning with Open Refine

  • Introduction to OpenRefine
  • Importing data
  • Data faceing with OpenRefine
  • Clustering With OpenRefine
  • Reference...

Data Analysis with R

  • Introduction to R
  • Starting with data
  • Aggregating and analyzing data with dplyr
  • Data visualization with ggplot2
  • Reference...

Manuscript Preparation with RMarkdown in R

  • Basics of R Makdown
  • Pandoc Markdown
  • Output formats(pdf, Latex, book, Journals etc)
  • Biblography and citations
  • Compiling Reports from R scripts
  • Article Writing
  • Reference...

Requirements: The training is hands-on, so participants are encouraged to bring in and use their own laptops to insure the proper setup of tools for an efficient workflow once you leave the workshop. (We will provide instructions on setting up the required software several days in advance) There are no pre-requisites, and we will assume no prior knowledge about the tools.

Software Setup

To participate in a training workshop, you will need working copies of the software described below. Please make sure to install everything and try opening it to make sure it works before the start of your workshop. If you run into any problems, please feel free to email the instructor or arrive early to your workshop on the first day. Participants should bring and use their own laptops to insure the proper setup of tools for an efficient workflow once you leave the workshop.

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.

A spreadsheet program

For this workshop you will need a spreadsheet program. Many people already have Microsoft Excel installed, and if you do, you're set! If you need a spreadsheet program, there are a few other options, like OpenOffice and LibreOffice. Install instructions for LibreOffice, which is free and open source, are here.

Windows

  1. Download the LibreOffice installer.
  2. Double click to install
  3. Double click on icon to open.

Mac OS X

  1. Download the LibreOffice installer.
  2. Double click to install
  3. Double click on icon to open.

Linux

  1. Download the LibreOffice installer.
  2. Double click to install
  3. Double click on icon to open.

OpenRefine

OpenRefine (previously Google Refine) is a tool for data cleaning that runs through a web browser, and any browser - Safari, Firefox, Chrome, Explorer - should work fine. You will need to download OpenRefine and install it, and when you open it, it will run through the browser, but you don't need an internet connection, and the data will all be stored on your computer.

Windows

  1. Download OpenRefine Windows kit installer.
  2. To use it, unzip, and double-click on openrefine.exe (if you're having issues with openrefine.exe try refine.bat instead)
  3. OpenRefine will then open in your web browser.
  4. If it doesn't open automatically, open a web broswer after you've started the program and go to the URL http://localhost:3333 and you should see OpenRefine.

Mac OS X

  1. Download OpenRefine Mac kit installer.
  2. Open the downloaded .dmg file
  3. Drag the icon in to the Applications folder
  4. Double click on the icon and Google Refine will then open in your web browser.
  5. If it doesn't open automatically, open a web broswer after you've started the program and go to the URL http://localhost:3333 and you should see OpenRefine.

Linux

  1. Download OpenRefine Linux kit installer.
  2. To use it, extract, and type ./refine
  3. OpenRefine will then open in your web browser.
  4. If it doesn't open automatically, open a web broswer after you've started the program and go to the URL http://localhost:3333 and you should see OpenRefine.

R and RStudio

In the workshop, we will use RStudio. RStudio is a nice interface to the programming language R. To use RStudio, you need to install both R and RStudio.

Windows

  1. Download R from here
  2. Run the .exe file that was just downloaded
  3. Go to the RStudio Download page
  4. Under Installers select RStudio x.yy.zzzz - Windows XP/Vista/7/8
  5. Double click the file to install it
  6. Once it's installed, open RStudio to make sure it works and you don't get any error messages.

Mac OS X

  1. Go to CRAN and click on Download R for (Mac) OS X
  2. Select the .pkg file for the version of OS X that you have and the file will download.
  3. Double click on the file that was downloaded and R will install
  4. Go to the RStudio Download page
  5. Under Installers select RStudio x.yy.zzz - Mac OS X 10.6+ (64-bit) to download it.
  6. Once it's downloaded, double click the file to install it
  7. Once it's installed, open RStudio to make sure it works and you don't get any error messages.

Linux

  1. Follow the instructions for your distribution from CRAN. For most distributions, you can use your package manager (e.g. for Debian/Ubuntu run sudo apt-get install r-base, and for Fedora run sudo yum install R) but make sure that you have at least R 3.2.2 (as pre-packaged versions might be out of date).
  2. To install RStudio, go to the RStudio Download page
  3. Under Installers select the version for your distribution.
  4. Once it's downloaded, double click the file to install it (or sudo dpkg -i rstudio-x.yy.zzz-amd64.deb at the terminal).
  5. Once it's installed, open RStudio to make sure it works and you don't get any error messages.