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

started inverse knitr

parent 9d39280c
No related branches found
No related tags found
No related merge requests found
## just knit R documents as they are, no markdown is required (but supported to some extent)
rknit(){
rscript=$1
tmdRmd=$(mktemp --suff .Rmd)
echo '# '$(basename $rscript .R) >> $tmdRmd
echo '```{r} ' >> $tmdRmd
cat $rscript >> $tmdRmd
echo '```' >> $tmdRmd
echo "require(knitr); knit2html('$tmdRmd')" | R --vanilla -q
}
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