UKZN, Bioresources Engineering

Jul 10-11, 2018

09:00 - 17:00

Instructors: Katrin Tirok, Justin Pringle, San Emmanuel James

Helpers: Atish Deoraj, Roanne Sutcliffe, Tadiwanashe Gutsa, Thomas Rowe

This workshop is organised in-house and is specifically aimed at postgraduate students and academic staff from the Department of Bioresources Engineering. No prior programming experience is required. Participants will be introduced to foundational concepts of data handling and programming in Python. The curriculum does not include statistics or mathematics.

General Information

Data Carpentry workshops are for any researcher who has data they want to analyze, and no prior computational experience is required. This hands-on workshop teaches basic concepts, skills and tools for working more effectively with data.

We will cover Data Organization in spreadsheets, Introduction to Python, Data Analysis and Visualisation in Python, Data Management with SQL and Developing post-workshop learning communities. Participants should bring their laptops and plan to participate actively. By the end of the workshop learners should be able to more effectively manage and analyze data and be able to apply the tools and approaches directly to their ongoing research.

For more information on what we teach and why, please see our paper "Best 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: CEAD computer lan, ICFR building, Agric Campus, Pietermaritzburg. Get directions with OpenStreetMap or Google Maps.

When: Jul 10-11, 2018. Add to your Google Calendar.

Requirements: As a participants you should bring your own laptop with Mac, Linux, or Windows operating system (not a tablet, Chromebook, etc.) that you have administrative privileges on. You need to install a few specific software packages before the workshop (listed below). If you can't bring your own laptop, you can use one of the desktop computers in the venue which will have all the necessary software. All participants are also required to abide by Data Carpentry's Code of Conduct.

Contact: Please email 209510188@stu.ukzn.ac.za or tirok@ukzn.ac.za for more information.


Schedule

Surveys

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

Pre-workshop Survey

Post-workshop Survey

Day 1 - Tuesday 10 Jul

Day 2 - Wednesday 11 Jul

08:30 Doors open/ Coffee 08:30 Doors open/ Coffee
09:00 Ice Breaker/Introductions 09:00 Warm up
09:30 Data organisation in Spreadsheets 9:30 Data Management with SQL
11:00 Coffee 11:00 Coffee
11:20 Introduction to Python 11:20 Data Management with SQL
12:50 Lunch 12:50 Lunch
13:30 Data analysis and visualisation with Python 13:30 Data analysis and visualisation with Python
15:00 Coffee 15:00 Coffee
15:15 Python continued 15:15 Python continued
16:45 Wrap up 16:45 Wrap up
17:00 End 17:00 End

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


Syllabus

Data organisation in spreadsheets

  • Formatting data tables in spreadsheets
  • Dates as data
  • Quality control
  • Exporting data
  • Reference...

Data analysis and visualisation in Python

  • Data types
  • Working with data
  • Data visualisation
  • Accessing SQL data bases
  • Reference...

Managing Data with SQL

  • Reading and sorting data
  • Filtering with where
  • Calculating new values on the fly
  • Handling missing values
  • Combining values using aggregation
  • Combining information from multiple tables using join
  • Creating, modifying, and deleting data
  • Programming with databases
  • Reference...

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.

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.

Python

Python is a popular language for research computing, and great for general-purpose programming as well. Installing all of its research packages individually can be a bit difficult, so we recommend Anaconda, an all-in-one installer.

Regardless of how you choose to install it, please make sure you install Python version 3.x (e.g., 3.6 is fine).

Windows

Video Tutorial
  1. Open http://continuum.io/downloads with your web browser.
  2. Download the Python 3 installer for Windows.
  3. Install Python 3 using all of the defaults for installation except make sure to check Make Anaconda the default Python.

Mac OS X

Video Tutorial
  1. Open http://continuum.io/downloads with your web browser.
  2. Download the Python 3 installer for OS X.
  3. Install Python 3 using all of the defaults for installation.

Linux

  1. Open http://continuum.io/downloads with your web browser.
  2. Download the Python 3 installer for Linux.
    (The installation requires using the shell. If you aren't comfortable doing the installation yourself stop here and request help at the workshop.)
  3. Open a terminal window.
  4. Type
    bash Anaconda3-
    and then press tab. The name of the file you just downloaded should appear. If it does not, navigate to the folder where you downloaded the file, for example with:
    cd Downloads
    Then, try again.
  5. Press enter. You will follow the text-only prompts. To move through the text, press the space key. Type yes and press enter to approve the license. Press enter to approve the default location for the files. Type yes and press enter to prepend Anaconda to your PATH (this makes the Anaconda distribution the default Python).
  6. Close the terminal window.

SQLite

SQL is a specialized programming language used with databases. We use a simple database engine called SQLite in our lessons.

Windows

The Data Carpentry Windows Installer installs SQLite for Windows. If you used the installer to configure nano, you don't need to run it again.

Mac OS X

SQLite comes pre-installed on Mac OS X.

Linux

SQLite comes pre-installed on Linux.

If you installed Anaconda, it also has a copy of SQLite without support to readline. Instructors will provide a workaround for it if needed.

SQLite Manager

To interact with SQLite data bases we will use the SQLite Manager add on for the Firefox web browser. If you don’t have Firefox installed, you need to install it first and then you will be able to add the plugin. You need to install the special Extended Support Release (ESR 52.x) of Firefox since the add on is not working with the new Firefox Quantum.

Windows

If you don’t already have Firefox ESR, download the Firefox ESR installer. Install Firefox ESR following the installer instructions. To install the SQLite Manager add on go to https://addons.mozilla.org/en-US/firefox/addon/sqlite-manager/ within Firefox. Click on ‘Add to Firefox’ and follow the instructions. Add SQLite Manager to the menu: Menu (the three horizontal lines near the top right corner of Firefox) -> Customize, then drag the SQLite Manager icon to one of the empty menu squares on the right

Mac OS X

If you don’t already have Firefox ESR, download the Firefox ESR installer. Install Firefox ESR following the installer instructions. To install the SQLite Manager add on go to https://addons.mozilla.org/en-US/firefox/addon/sqlite-manager/ within Firefox. Click on ‘Add to Firefox’ and follow the instructions. After restart the SQLite Manager will be added ot the Tools menu.

Linux

If you don’t already have Firefox ESR, download the Firefox ESR installer. Install Firefox ESR following the installer instructions. To install the SQLite Manager add on go to https://addons.mozilla.org/en-US/firefox/addon/sqlite-manager/ within Firefox. Click on ‘Add to Firefox’ and follow the instructions. After restart the SQLite Manager will be added ot the Tools menu.