From 1cba9df7db76db2d2f914ce2a291022cefacc71f Mon Sep 17 00:00:00 2001 From: Preston Burns Date: Wed, 6 Feb 2019 11:02:48 -0500 Subject: [PATCH 1/3] clarify code section of html report #149 --- .../renderChart/eDishReport/eDishReport.Rmd | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/inst/eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd b/inst/eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd index 8ab2edab..5a49eb21 100644 --- a/inst/eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd +++ b/inst/eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd @@ -35,9 +35,22 @@ safetyGraphics is an open source project built using standard web technology and
-#### Code +#### Code to Reproduce Chart + +Retrieve Data +```{r, comment=NA, echo=FALSE, tidy=TRUE} + +writeLines("path <- 'path_to_data'") +writeLines("my_data <- read.csv(file.path(path, 'data.csv'))") + +``` + +`r print("path <- 'path_to_data'", quote = FALSE)` + +Generate Chart ```{r, comment=NA, echo=FALSE} -graphic_code <- bquote(eDISH(data = params$data, + +graphic_code <- bquote(eDISH(data = my_data, settings = .(params$settings))) graphic_code From 714aa6009d5b93e3920834f36482c393e00e030d Mon Sep 17 00:00:00 2001 From: Preston Burns Date: Wed, 6 Feb 2019 11:06:39 -0500 Subject: [PATCH 2/3] clean up --- .../eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/inst/eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd b/inst/eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd index 5a49eb21..2df10d83 100644 --- a/inst/eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd +++ b/inst/eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd @@ -38,15 +38,13 @@ safetyGraphics is an open source project built using standard web technology and #### Code to Reproduce Chart Retrieve Data -```{r, comment=NA, echo=FALSE, tidy=TRUE} +```{r, comment=NA, echo=FALSE} writeLines("path <- 'path_to_data'") writeLines("my_data <- read.csv(file.path(path, 'data.csv'))") ``` -`r print("path <- 'path_to_data'", quote = FALSE)` - Generate Chart ```{r, comment=NA, echo=FALSE} From d20b76fc848c9ed910a34fe60e73fbb807d875e6 Mon Sep 17 00:00:00 2001 From: jwildfire Date: Wed, 6 Feb 2019 09:47:20 -0800 Subject: [PATCH 3/3] Update eDishReport.Rmd --- .../modules/renderChart/eDishReport/eDishReport.Rmd | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/inst/eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd b/inst/eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd index 2df10d83..2860bada 100644 --- a/inst/eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd +++ b/inst/eDISH_app/modules/renderChart/eDishReport/eDishReport.Rmd @@ -37,17 +37,12 @@ safetyGraphics is an open source project built using standard web technology and #### Code to Reproduce Chart -Retrieve Data -```{r, comment=NA, echo=FALSE} - -writeLines("path <- 'path_to_data'") -writeLines("my_data <- read.csv(file.path(path, 'data.csv'))") +Use the script below to (1) load your data and (2) render the chart. Make sure to update the first line to point at your data. -``` - -Generate Chart ```{r, comment=NA, echo=FALSE} +writeLines("path <- 'path_to_data'") ### <-- Update this! +writeLines("my_data <- read.csv(file.path(path, 'data.csv'))") graphic_code <- bquote(eDISH(data = my_data, settings = .(params$settings)))