In this exercise, each participant will fork a github repo, and contribute a file required to simulate the evolutionary trajectory of an imaginary species’ body size.
We’ll use github to collate all species files and plot them all up together at the end! We’ll also discover the skull and beak shapes associated with each simulated species size.
github: make your own copy of the repository** on github
github: Github makes a copy into your account
github: clone it: copy repo link to initiate Rstudio project
rstudio: Create new project
rstudio: Checkout from version control repository
rstudio: Clone project from a git repository
rstudio: Paste repo link copied from Github into Repository URL field. Click Create Project
.
rstudio: Rstudio project now contains all files from the github repo.
rstudio: open params/params_tmpl.R
rstudio: save as new .R
script in params/
folder. Use species name of your choice to name new file. Please to not overwrite file params/params_tmpl.R
.
rstudio: edit file with parameters of your choice and save.
The parameters each participants need to supply are:
sig2
: A numeric value greater than 0 but smaller than 5
species.name
: a character string e.g. "anas_krystallinus"
. Try to create a species name out of your name!
color
: a character string e.g. "red"
, "#FFFFFF"
(tip: pick a color using Rstudio’s Color picker:)
rstudio: in the git tab, select the new file you created and click Commit
rstudio: write an informative commit message and click Commit
rstudio: your new file has now been commited
rstudio: on the git tab click ⇧ to push changes to Github
rstudio: changes have now been updated in the Github repo
github: in your repository, create new pull request
to merge fork to master repo (ie the original repo you forked)
github: github checks whether your requested merge creates any coflicts. If all is good, click on Create pull request
github: write an informative message, explaining your changes to the master repo administrators. Click on Create pull request
github: check original repo to see your merged changes
.R
script. Name it using your selected species name.We’ll merge all contributions and plot them together at the end!
Karthik Ram’s article: ‘Git can facilitate greater reproducibility and increased transparency in science’
Getting started with GitHub from materials for a software carpentry course at UBC
Slides for lecture Karl Broman gave on git/github, with notes
joeyklee’s friendly github intro. Mozilla Science Lab workshop