Don't just sit there: interact!

Building interactive data exploratory apps with #shinyapps & @plotlygraphs


Anna Krystalli @annakrystalli
annakrystalli@googlemail.com
MolEcol group meeting, 1 Dec 2015

Overview


  • demo of shiny app, developed for the 'Evolution of Sex Roles in Birds' project
    • demonstrate some open source tools and resources currently available through R
    • show that adopting open science practices can boost group productivity and scientific insight

Evolution of Sex Roles in Birds project

Compile large dataset on bird reproductive, morphological, life history and ecological traits across as many bird species as possible

  • Primarily a data management project: dataset & code the outputs

    • 1,307,253 data points
    • 202 variables

An Open Science perspective

  • transparency
    • track provenance
  • reproducibility
  • foster collaboration
  • promote diversity of scientific output

good data management - version control - good documentation - open collaborative workflows


more:
@billdoesphysics @swcarpentry

Data management



Initial wide data structure

  • qc & ref variables mixed in
  • unable to handle duplicate datapoints

Redesigned data collation workflow

  • database of datapoints
  • qc & ref datapoint metadata

markdown reporting


markdown.md

The future: project Jupyter hints at academic journals of tomorrow

Eureka moment - let's build an app


Key functions:

  • allow user to explore dataset
  • be flexible and interactive
  • allow data extraction

Features:

  • Used shiny to build a user friendly interface to access only information of interest
  • Integrate plotly to make plots interactive - give user control
  • Publish online with shinyapps.io: easy access for all members of group

App structure & demo


Backend: 2 datasets

  1. wide dataset
  2. metadata file

Launch Demo

App info


my code on github

additional code required to run plotly

by cldougl
more info here


pay particular attention to file: global.R,

I believe plotlyGraphWidget.R, and www/plotlyGraphWidget.js are deprecated

Not quite the fairy tale ending...yet


Hosting issues:

authorisation to access only available on subscription


The future:

academic subscriptions

Take home


  • open source an adaptive radiation of tools & resources available to all

  • open science practices can improve workflows at all levels

  • Engagement, participation & capacity building at the lab level can have huge benefits

  • Be creative think more broadly about scientific output

Resources