Sharing reproducible and interactive environments in R with Binder

By Florencia D'Andrea in Reproducibility

August 28, 2020

Working in a reproducible manner

I’m trying to make my next paper easier to reproduce. This has led me to read about computational reproducibility tools and get involved in communities like ReproHack, where the focus is on elucidating best practices when sharing your code and data.

Do you want to know more about ReproHack and computational reproducibility? I recommend Anna Krystalli’s talk on UseR! 2020

Binder and R?

I got to know Binder thanks to the Ines Montani tutorial framework. In this framework, Binder allows you to run the code of the exercises interactively.

One of the benefits of Binder is being able to share Shiny apps, although it has some disadvantages compared to shinyapps.io. “Binderized” Shiny apps take longer to build but it is still an interesting alternative when leaving an application as part of a publication. It also has no restrictions on the number of apps that can be left for free. In addition, by simply changing the URL that we use to call the app, Binder allows us to access the same project using the RStudio IDE.

If you want to deploy your Shiny app using shinyapps.io you can find instructions in this webpage

A short time ago I participated in CarpentryCon, not only helping in the translations of lessons into Spanish, but also giving a small workshop with Pablo Bernabeu on Reproducibility and Open Science where I briefly explained the use of Binder for R users.

If you want to know more about Binder, I suggest The Turing Way book. The Turing Way is another community that I recommend you follow if you are interested in the topic of open science and reproducibility.

Tutorials: Binder is part of the Inés Montani framework for R and Python tutorials and can also be used to share learnR tutorials as it is explained in this blog post

Slides

I prepared these slides as part of a meetup to present the first ReproHack in Spanish to be held at the LatinR 2020 conference.

In these slides you can find:

  • Different ways to capture computational environments

  • A brief overview of the renv package

  • What Binder is

  • Steps to share interactive environments with Binder.

Slides in English.

Slides in Spanish.

Final note

Due to changes to Docker terms of service on November 1st the lack of activity for 6 months may cause the sharing link to become inactive. You can ask questions about Binder in the following link https://discourse.jupyter.org/