Skip to content
Snippets Groups Projects
Commit 410c6695 authored by Holger Brandl's avatar Holger Brandl
Browse files

cont. rna-seq workflow

parent 63913ede
No related branches found
No related tags found
No related merge requests found
...@@ -11,10 +11,10 @@ options(width=150) ...@@ -11,10 +11,10 @@ options(width=150)
## better table css: http://www.stat.ubc.ca/~jenny/STAT545A/topic10_tablesCSS.html ## better table css: http://www.stat.ubc.ca/~jenny/STAT545A/topic10_tablesCSS.html
spin(rScript, knit=F) spin(rScript, knit=F)
mdScript <- str_replace(rScript, "[.]R$", ".Rmd") rmdScript <- str_replace(rScript, "[.]R$", ".Rmd")
system(paste("mv", mdScript, "tmp.Rmd")) system(paste("mv", rmdScript, "tmp.Rmd"))
system(paste("cat tmp.Rmd | grep -Ev '^#+$' | grep -Fv '#!/usr/bin/env Rscript' >", basename(mdScript))) system(paste("cat tmp.Rmd | grep -Ev '^#+$' | grep -Fv '#!/usr/bin/env Rscript' >", basename(rmdScript)))
file.remove("tmp.Rmd") file.remove("tmp.Rmd")
cssHeader=' cssHeader='
...@@ -27,6 +27,8 @@ cssHeader=' ...@@ -27,6 +27,8 @@ cssHeader='
## custom title http://stackoverflow.com/questions/14124022/setting-html-meta-elements-with-knitr ## custom title http://stackoverflow.com/questions/14124022/setting-html-meta-elements-with-knitr
opts_chunk$set(cache = TRUE, fig.width=10, width=120) opts_chunk$set(cache = TRUE, fig.width=10, width=120)
knit2html(basename(mdScript), header=cssHeader) knit2html(basename(rmdScript), header=cssHeader)
file.remove(basename(mdScript)) file.remove(basename(rmdScript))
file.remove(basename(str_replace(rScript, "[.]R$", ".md")
))
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment