R packaging

Netherlands eScience Center

Online

March 22 - 24, 2022

9:00 - 13:00 CET

Instructors: Pablo Rodríguez-Sánchez, Lieke de Boer, Barbara Vreede

Helpers: Dafne van Kuppevelt, Candace Moore

Some adblockers block the registration window. If you do not see the registration box below, please check your adblocker settings.

General Information

The Digital Skills programme at the Netherlands eScience Center focuses on the foundational digital skills needed to put reproducible research into practice. The workshops we run cover the essentials of version control, online collaboration, reproducible code and good programming practices.

This workshop will provide you with the basics for writing your own packages in R.

R packages are no more and no less than a standard way of structuring your work. You’ll have a folder for code, a folder for tests, a folder for data, a folder for documents, and so on. The standardization makes packages easily installable and shareable.

Even if you are not planning to publish your package, structuring your research as one is also a very good idea. It enforces, in a relatively effortless manner, the implementation of software development best practices. This will lead to a safer, more robust, more manageable and more enjoyable working experience.

Who: 

The participants should:

  • Be familiar with R and RStudio.
  • Know how to create their own R functions.

Where: This training will take place online. The instructors will provide you with the information you will need to connect to this meeting.

When: March 22 - 24, 2022.

Requirements: Participants must have access to a computer 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).

Accessibility: We are dedicated to providing a positive and accessible learning environment for all. Please notify the instructors in advance of the workshop if you require any accommodations or if there is anything we can do to make this workshop more accessible to you.

Contact: Please email or training@esciencecenter.nl for more information.


Code of Conduct

Participants are expected to follow those guidelines:

Syllabus

Schedule

Day 1. Tue 22 March 2022

09:00 Welcome and icebreaker
09:15 Introduction
10:15 Coffee break
10:30 Accessing packages
11:30 Coffee break
11:45 Getting started
12:45 Wrap-up
13:00 END

Day 2. Wed 23 March 2022

09:00 Welcome and icebreaker
09:15 Writing our own functions
10:15 Coffee break
10:30 Testing
11:30 Coffee break
11:45 Documenting your packages
12:45 Wrap-up
13:00 END

Day 3. Thu 24 March 2022

09:00 Welcome and icebreaker
09:15 Managing dependencies
10:15 Coffee break
10:30 Data
11:30 Coffee break
11:45 Vignettes
12:45 Wrap-up
13:00 END

All times in the schedule are in the CET timezone (Amsterdam time).


Setup

To participate in this workshop, you will need access to software as 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.

Install the videoconferencing client

If you haven't used Zoom before, go to the official website to download and install the Zoom client for your computer.

Set up your workspace

Like other Carpentries workshops, you will be learning by "coding along" with the Instructors. To do this, you will need to have both the window for the tool you will be learning about (a terminal, RStudio, your web browser, etc..) and the window for the Zoom video conference client open. In order to see both at once, we recommend using one of the following set up options:

This blog post includes detailed information on how to set up your screen to follow along during the workshop.

Install R, RStudio and required packages

This lesson assumes you have current versions of the following installed on your computer:

  1. the R software itself, and
  2. RStudio Desktop.

You’ll also need to install the following packages:

They can be installed by typing the code below in the R console:

$ install.packages(c("devtools", "rmarkdown", "roxygen2"))

If the installation went right, the code below should throw no errors:

$ library(devtools)
$ library(rmarkdown)
$ library(roxygen2)

Please contact us in advance if you are experiencing problems.