Code Monkey home page Code Monkey logo

rmd_workshop's Introduction

Writing Reproducible Research Papers with R Markdown

This repository holds the materials for a workshop on writing reproducible research papers with R Markdown, first taught at Campus Luzern in March 2020.

Unless otherwise noted, all material is copyright Resul Umit, licensed CC-BY-SA 3.0. An easy to read summary of this permissive licence is available on the Creative Commons website.

Contents

The workshop is divided into ten parts. Most parts include exercises โ€” 40+ in total.

Part 1. Getting the Tools Ready
- e.g., downloading course material
Part 6. Adding Code, Figures, and Tables
- e.g., plotting data
Part 2. Introducing R Markdown
- e.g., creating a new document
Part 7. Addressing Functionality Gaps
- e.g., adjusting line spacing
Part 3. Setting Metadata
- e.g., defining output format
Part 8. Using Version Control
- e.g., integrating Git and GitHub
Part 4. Writing Text
- e.g., adding emphasis to text
Part 9. Collaborating with Others
- e.g., working simultaneously with co-authors
Part 5. Managing References
- e.g., citing sources
Part 10. Working on a Real Project
- e.g., converting a work-in-progress of yours

Slides

The slides for the workshop are available to view at https://resulumit.com/teaching/rmd_workshop.html. These HTML slides are created with xaringan package (Xie, 2020).

See the presentation directory of this repository for the source files underlying the slides. The same directory also includes the PDF version of the slides, which might come handly if the HTML version is too large for your browser to function. This is indeed a known problem for some Safari users.

Materials

The remaining workshop materials are available in a separate branch of this repository, called materials. It includes the following:

  • manuscript\reproduce_this.pdf

    • a document, formatted in Word but saved as PDF, to be re-created with R Markdown
    • random sentences in the document are generated with the stringi package (Gagolewski, 2020)
    • figures and tables are based on a fabricated dataset (journals.csv, see below)
    • key sections in-need of attention are highlighted
  • manuscript\journals.Rmd

    • an R Markdown document to work on during the workshop
      • includes unformatted text from reproduce_this.pdf to save time
      • major components, such as paragraphs and tables, are numbered and marked in comments to facilitate navigation
  • manuscript\references.bib

    • a BibTeX document with three fabricated references
  • manuscript\apa_7th.csl

    • a Citation Style Language document, with APA (7th Edition) referencing style (Wiernik, 2020)
  • data\journals.csv

    • a dataset created with the fabricatr package (Blair et al., 2019), imagined to explore the Google Scholar rankings of fictitious journals

    • includes the following variables

      • name: journals (1090 random titles)
      • origin: geographic origins (five continents)
      • branch: major discipline of journals (four branches)
      • since: time of first publication (years)
      • h5_index: H5 Index (integers)
      • h5_median: H5 Median (integers)
      • english: English (1) vs. other-language (0) journals
      • subfield: subfield (1) vs. generalist (0) journals
      • issues: number of issues published per year (integers)
  • image\google_scholar.png

    • a screeenshot image of the Google Scholar homapage, copyright Google, LLC
  • test\run_this.R

    • an R script that
      • installs the packages needed for the workshop
      • attempts to knit an R Markdown into PDF file
    • useful for tasking participants with a pre-workshop setup
  • test\the_test.Rmd

    • an R Markdown file, to be used for the attempt in test\run_this.R

References

Blair, G., Cooper, J., Coppock, A., Humphreys, M., Rudkin, A. and Fultz, N. (2019). fabricatr: Imagine your data before you collect it. R package, version 0.10.0.

Gagolewski, M. (2020). stringi: Character String Processing Facilities. R package, version 1.4.6.

Wiernik, B. M. (2020). American Psychological Association 7th edition (no ampersand). Citation style language file, version 1.0.

Xie, Y. (2020). xaringan: Presentation Ninja. R package, version 0.18.

rmd_workshop's People

Contributors

resulumit avatar indrajeetpatil avatar rumit-workshop 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.