Skip to content

Instantly share code, notes, and snippets.

@nicolasDelhomme
Last active December 15, 2023 18:27
Show Gist options
  • Save nicolasDelhomme/cf62d4b761cf9fa6ff7c998b0041ff62 to your computer and use it in GitHub Desktop.
Save nicolasDelhomme/cf62d4b761cf9fa6ff7c998b0041ff62 to your computer and use it in GitHub Desktop.
Biological quality assessment (exploratory data analysis)

Reproducible research

The goal of this git crash course intro is to introduce you to tools for reproducible research (RR). To ensure RR, we need at least two components:

  1. the data (that has to be published upon manuscript acceptance by most journal standards)
  2. the code (yes how you ran your analysis!)

There are extra components (tools, version, providing these in containers), but let's focus on 2.

Git

Intro

That book is a great resource. We only need to know a little to get started. In your own time, look at Chapter 1, section 1. to 4 and once you start using it Chapter 2 is all you need (99% of the time).

Guided example

  1. Open your RStudio.
  2. Click on File > New Project > Version Control > GitHub
  3. As a repository URL, paste https://github.com/nicolasDelhomme/BioQAExample.git
  4. Click Create Project

That's it, you have made a copy of the repository that contains the code for the next guided session!

Advanced

That repository actually exists in multiple flavours :-) i.e. it has what is called in git different branches. There is one such branch that is specific for the course.

In RStudio, go to the Git tab, in the quadrant with the Environment, History, etc. Once in the Git tab, to the right of the menu at the top of that quadrant, click on the drop-down menu currently showing main and select non-model. It will update your repository to the content specific for this workshop.

Branches in git are mostly used during software development, typically to test novel ideas that would require a significant rewrite of the code base. Very often, you would have main as being the stable copy and dev being a branch where you would try possibly disruptive (but hopefully super cool) changes.

Practice

That's not meant for today, but for a future refresher :-)

  1. If you want to practice reproducible research and do the BioQA on the data from this workshop, follow the steps in the README of the repository you cloned.
  2. If you are stuck, look at the BiologicalQA_ND.R script.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment