comparison rmarkdown_report.Rmd @ 0:7a3bb304fe1d draft

planemo upload
author mingchen0919
date Mon, 14 May 2018 15:56:28 -0400
parents
children 350afb9412fc
comparison
equal deleted inserted replaced
-1:000000000000 0:7a3bb304fe1d
1 ---
2 title: 'Aurora Tool Report'
3 output:
4 html_document:
5 highlight: pygments
6 ---
7
8 ```{r setup, include=FALSE, warning=FALSE, message=FALSE}
9 knitr::opts_chunk$set(error = TRUE, echo = FALSE)
10 ```
11
12 ```{css echo=FALSE}
13 # code chunks scrollable
14 pre code, pre, code {
15 white-space: pre !important;
16 overflow-x: scroll !important;
17 word-break: keep-all !important;
18 word-wrap: initial !important;
19 }
20 ```
21
22
23 ```{r, echo=FALSE}
24 # to make the css theme to work, <link></link> tags cannot be added directly
25 # as <script></script> tags as below.
26 # it has to be added using a code chunk with the htmltool functions!!!
27 css_link = tags$link()
28 css_link$attribs = list(rel="stylesheet", href="vakata-jstree-3.3.5/dist/themes/default/style.min.css")
29 css_link
30 ```
31
32 ```{r, eval=FALSE, echo=FALSE}
33 # this code chunk is purely for adding comments
34 # below is to add jQuery and jstree javascripts
35 ```
36 <script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
37 <script src="vakata-jstree-3.3.5/dist/jstree.min.js"></script>
38
39 ---
40 # javascript code below is to build the file tree interface
41 # see this for how to implement opening hyperlink: https://stackoverflow.com/questions/18611317/how-to-get-i-get-leaf-nodes-in-jstree-to-open-their-hyperlink-when-clicked-when
42 ---
43 <script>
44 $(function () {
45 // create an instance when the DOM is ready
46 $('#jstree').jstree().bind("select_node.jstree", function (e, data) {
47 window.open( data.node.a_attr.href, data.node.a_attr.target )
48 });
49 });
50 </script>
51
52 ---
53 # ADD YOUR DATA ANALYSIS CODE AND MARKUP TEXT BELOW TO EXTEND THIS R MARKDOWN FILE
54 ---
55
56 ## Job script
57
58 ```{bash, echo=FALSE}
59 sh ${TOOL_INSTALL_DIR}/build-and-run-job-scripts.sh > ${REPORT_FILES_PATH}/log.txt 2>&1
60 ```
61
62 ```{r echo=FALSE, comment='', results='asis'}
63 cat('```bash\n')
64 cat(readLines(paste0(Sys.getenv('REPORT_FILES_PATH'), '/curl-download.sh')), sep = '\n')
65 cat('\n```')
66 ```
67
68 ```{bash, echo=FALSE}
69 # create a directory in current working directory and copy the downloaded file into that directory
70 mkdir -p output_dir
71 cp output.$X_n output_dir
72 ```
73