##this file is used to update the README.md from the package vignette ##(credit for the idea and implementation in this packages goes to Thibuat Jombart) ##to update README.md, simply run: ##knitr::knit("README.Rmd")
##delete old figures file.remove(dir("vignettes/figure",full.names = T)) ## recompile vignette setwd("vignettes") knitr::knit("mtDNAcombine.Rmd") setwd("../")
## read md of the vignette mdInput <- readLines("vignettes/mtDNAcombine.md") ## remove vignette-specific headers toRemove <- 1:12 mdInput <- mdInput[-toRemove] ## add badges circleci_img <- '[](https://circleci.com/gh/EvolEcolGroup/mtDNAcombine/tree/master)' ## Add badge for Circleci mdInput[2] <- paste(circleci_img) ## restore right path for figures ## pick wd path depending on operating system ## LINUX #foo <- '/home/eleanor/' ## Windows foo <- 'C:/Users/mille/' mdInput <- gsub(paste0(foo,"Documents/Projects/mtDNAcombine/inst/extdata/mtDNAcombine_flow.png"), "./inst/extdata/mtDNAcombine_flow.png", mdInput) mdInput <- gsub(paste0(foo,"Documents/Projects/mtDNAcombine/inst/extdata/hist_Pinicola_enucleator.png"), "./inst/extdata/hist_Pinicola_enucleator.png", mdInput) mdInput <- gsub(paste0(foo,"Documents/Projects/mtDNAcombine/inst/extdata/hist_Calidris_maritima.png"), "./inst/extdata/hist_Calidris_maritima.png", mdInput) mdInput <- gsub(paste0(foo,"Documents/Projects/mtDNAcombine/inst/extdata/Net_Picoides_tridactylus.png"), "./inst/extdata/Net_Picoides_tridactylus.png", mdInput) mdInput <- gsub("figure/plotting median-1.png", "./inst/extdata/common_rosefinch_BSP.png", mdInput) cat(paste(mdInput,collapse="\n"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.