Code Monkey home page Code Monkey logo

sandbox's Introduction

sandbox

Click Binder. This will open a new page with RStudio in a virtual environment (VE). If not, a page that says binder at the top will open. Wait for the VE to be built (this may take a few minutes).

Within the VE, you can run scripts as you would on a local machine, or upload your Rmarkdown file and knit it to the desired output (pdf, html, etc.) If the output is successfully knitted, it means that you have in principle achieved reproducibility. If it cannot be knitted but it worked on your local machine, the first thing to check is if there are absolute paths (explanation) in your script. Change them to relative paths, and knitting should work again.

Even if knitting an Rmd file works, there are several commands that you need to ensure are not in it:

  1. install.packages(): when someone else tries to reproduce your output, you don't want this command to mess up their machine.
  2. View(): this is a command most suitable for interactive analysis i.e. you type in the console and results appear. Rmarkdown is designed for non-interactive output generation, so you should not include any View() in an Rmd file.
  3. setwd(): The issue with this command is related to that for absolute paths. Also, this command should be used interactively, either in the console, or substituted by clicking Session $\rightarrow$ Set Working Directory in RStudio.

Acknowledgements go to Matt Ingram at Project TIER.

sandbox's People

Contributors

clement-lee avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.