1 Using R for data analysis

R is an open-source, free environment for statistical computing and graphics. It provides a large repository of statistical analysis methods, both classic and new. However, R has a steep learning curve, due partly to its using a command-line type of user interface, rather than the usual pull-down menus. The course aims at helping researchers climb this curve, enabling them to perform basic data analysis and graphic displays at the end of the course, as well as giving a platform from which they can deepen their R knowledge later on if necessary.

1.1 Teachers

In alphabetical order:

  • Jelle Goeman, Medical Statistics & Bioinformatics, LUMC
  • Szymon M. Kielbasa, Bioinformatics Center of Expertise, Medical Statistics & Bioinformatics, LUMC (coordinator at LUMC)
  • Renee Menezes, Department of Epidemiology and Biostatistics, VUmc (coordinator at VUmc)
  • Ramin Monajemi, Bioinformatics Center of Expertise, Medical Statistics & Bioinformatics, LUMC

1.2 Goals & Topics

After the course you will be able to:

  • understand and write simple R programs
  • use R to perform simple statistical analyses of your own data tables
  • generate analysis reports from your own data in html or pdf formats

We will cover the following topics:

  • R expressions
  • R data objects (vectors (arrays), data frames (tables), lists) creation and usage
  • R Markdown for building reproducible reports [cheat sheet]
  • R functions for descriptive statistics and linear model fitting; R formula objects
  • installing additional libraries
  • histograms, scatter plots, boxplots (in pure R and with ggplot2) [cheat sheet]
  • filtering, sorting, summarizing of a table; joining/merging multiple tables (with dplyr and tidyr) [cheat sheet]

1.3 Prerequisites

The course assumes no prior programming knowledge. Elementary statistics knowledge is necessary.

Participants must bring own laptops capable of running RStudio.

Before the course please prepare your laptop:

  • go to the RStudio download page, select a version of RStudio appropriate for your laptop, download it and then install. Please check whether you can start RStudio.
  • download the course materials .zip file (see below) to your laptop. Unpack the zip file to a directory, and please check whether you can open index.html file from the directory.

1.4 Materials

The course materials are served:

The materials contain a data directory with the data files used in the presentations/tasks. The directory can be also accessed at https://barmsijs.lumc.nl/R_course/data

1.5 Programme

1.5.1 as part of “Introduction Bioinformatics”: Sep. 20th — 27th, 2018

For this course there might still be free places. Please contact Madeleine Nivard (M.J.M.Nivard at lumc.nl) to check.

The primary source for dates/times/rooms is:

Date Time Room Teacher Slot
20-09-2018 09:00-12:00 B1-81_(route-15) Jelle slot 1
20-09-2018 13:00-16:00 B1-81_(route-15) Dani/Ramin/Szymon slot 2
21-09-2018 09:00-12:00 CZ-2_route-766 Jelle slot 3
21-09-2018 13:00-16:00 V4-50 Ramin slot 4
24-09-2018 09:00-12:00 J1-83_(route-555) ??? slot 5
24-09-2018 13:00-16:00 V4-50 ??? slot 6
25-09-2018 09:00-12:00 V4-18/22 ??? slot 7
25-09-2018 13:00-16:00 CZ-2 ??? slot 8
27-09-2018 15:00-17:00 CZ-3 ??? exam

1.5.2 as associated with CRiP: Sep. 28th-Oct. 16th, 2018

The primary source for dates/times/rooms is:

Date Time Room Teachers Slot
28-09-2018 09.30-12.30 ? Jelle slot 1
04-10-2018 08.30-12.30 J1-117_(route-554) Ramin slot 2
05-10-2018 13.30-17.30 V4-18/22 Jelle slot 3
09-10-2018 09.00-11.30 CZ-1_route-768 Ramin slot 4
09-10-2018 12.30-17.00 CZ-1_route-768 Ramin slot 5
11-10-2018 13.30-17.30 CZ-3 Dani slot 6
12-10-2018 13.30-17.30 V2-18/22 Ramin slot 7
16-10-2018 14.30-16.30 CZ-5_route-558 Ramin exam

The course will take place in LUMC.

1.5.3 VU edition: Jan. 28th — Feb. 1st, 2019

Date Time Room Teachers Slot
28-01-2019 09.00-12.30 De Waver ? slot ?
28-01-2019 13.30-17.00 De Waver ? slot ?
29-01-2019 09.00-12.30 De Waver ? slot ?
29-01-2019 13.30-17.00 De Waver ? slot ?
31-01-2019 09.00-12.30 De Waver ? slot ?
31-01-2019 13.30-17.00 De Waver ? slot ?
01-02-2019 09.00-12.30 De Waver ? slot ?
01-02-2019 13.30-17.00 De Waver ? slot ?

Possibly outdated 2018 info: http://www.bigstatistics.nl/teaching/

The rooms are located at VUmc.

1.8 Course recent history

1.8.1 LUMC Boerhaave Nascholing: June 4th-7th, 2018

Date Time Room Teacher(s) Slot
04-06-2018 09.00-12.30 J1-83 Jelle slot 1
04-06-2018 13.30-17.00 J1-83 Szymon slot 2
05-06-2018 09.00-12.30 J1-83 Renee slot 3
05-06-2018 13.30-17.00 J1-83 Ramin slot 4
06-06-2018 09.00-12.30 J1-83 Renee slot 5
06-06-2018 13.30-17.00 J1-83 Szymon slot 6
07-06-2018 09.00-12.30 J1-83 Jelle slot 7
07-06-2018 13.30-17.00 J1-83 Ramin slot 8

The course took place in LUMC, building 1 (main building).

Other info: https://www.boerhaavenascholing.nl/medische-nascholing/2018/using-r-for-data-analysis/

1.8.2 VU edition: Feb. 12th — 15th, 2018

More info: http://www.bigstatistics.nl/teaching/

Date Time Room Teachers Slot
12-02-2018 09.00-12.30 Leidseplein (198) Jelle (Armin) slot 1
12-02-2018 13.30-17.00 Leidseplein (198) Szymon slot 2
13-02-2018 09.00-12.30 Nieuwmarkt (202) Ramin slot 3
13-02-2018 13.30-17.00 Nieuwmarkt (202) Renee slot 4
14-02-2018 09.00-12.30 Leidseplein (198) Renee slot 5
14-02-2018 13.30-17.00 Leidseplein (198) Szymon slot 6
15-02-2018 09.00-12.30 De Dam (206) Jelle (Armin) slot 7
15-02-2018 13.30-17.00 De Dam (206) Ramin (Armin) slot 8/exam

The rooms are located at VUmc, Polyclinic building, 6th floor, aisle X (PK 6X).

1.8.3 as associated with CRiP: Sep. 29th, 2017 and Oct. 5th — 17th, 2017

Date Time Room Teachers Slot
29-09-2017 09.30-12.30 CZ-5 Jelle, Szymon, Nikos, Dani, Diaa slot 1
05-10-2017 08.30-12.30 V4-18/22 Szymon, Ramin slot 2
06-10-2017 09.00-13.00 J1-83 (route-555)
06-10-2017 13.00-15.00 J1-83 (route-555) Jelle, Diaa slot 3
06-10-2017 15.00-17.00 V4-50 Jelle, Diaa slot 3
10-10-2017 09.00-13.00 V2-18/22 Ramin, Szymon slot 4
10-10-2017 13.00-17.00 V2-18/22 Ramin, Szymon slot 5(6)
12-10-2017 13.30-17.30 V2-34 Szymon, Ramin slot 6(5)
13-10-2017 13.30-17.30 V3-36 Jelle, Diaa slot 7
17-10-2017 13.30-17.30 V4-62 Jelle, Ramin slot 8/exam

Additional teaching support: Nikos Pappas, Dani Borras, Diaa al Mohamad.

1.8.4 as part of “Introduction Bioinformatics”: Sep. 7th — 11th, 2017

Date Time Room Teacher Slot
07-09-2017 09:30-12:45 J1-84 Ramin slot 1
07-09-2017 13:45-17:00 J1-84 Szymon slot 2
08-09-2017 09:30-12:45 J1-84 Jelle slot 3
08-09-2017 13:45-17:00 J1-84 Ramin slot 4
11-09-2017 09:30-12:45 J1-84 Jelle slot 5
11-09-2017 13:45-17:00 J1-84 Szymon slot 6

The course took place in LUMC building 1, room J1-84. In this course iteration slot 7 and slot 8 were not presented.

1.8.5 organized by “Boerhaave Nascholing”: June 13th, 2017 — June 16th, 2017

The course was divided into 8 slots, 2 slots per day:

  • 09:30-12:45 (the morning slot)
  • 13:45-17:00 (the afternoon slot)

The course took place in LUMC, room J1-83.