@@ -21,7 +21,7 @@ various types of datasets using the scatter plot module `tm_g_scatterplot()`:
2121
2222## 1 - Load libraries
2323
24- ``` {r library, echo=TRUE, message=FALSE, warning=FALSE, results="hide"}
24+ ``` {r library, echo=TRUE, message=FALSE, warning=FALSE, results="hide", eval = requireNamespace("ggpmics") && requireNamespace("ggExtra") && requireNamespace("colourpicker") }
2525library(teal.modules.general) # used to create the app
2626library(dplyr) # used to modify data sets
2727library(ggpmisc)
@@ -38,7 +38,7 @@ Inside this app 4 datasets will be used
38383 . ` ADTTE ` A long data set with time to event data
39394 . ` ADLB ` A long data set with lab measurements for each subject
4040
41- ``` {r data, echo=TRUE, message=FALSE, warning=FALSE, results="hide"}
41+ ``` {r data, echo=TRUE, message=FALSE, warning=FALSE, results="hide", eval = requireNamespace("ggpmics") && requireNamespace("ggExtra") && requireNamespace("colourpicker") }
4242data <- teal_data()
4343data <- within(data, {
4444 ADSL <- teal.modules.general::rADSL %>%
@@ -64,7 +64,7 @@ create an app. The data will be handed over using `teal.data::teal_data()`. The
6464itself will be constructed by multiple calls of ` tm_g_scatterplot() ` using different
6565combinations of data sets.
6666
67- ``` {r app, echo=TRUE, message=FALSE, warning=FALSE, results="hide"}
67+ ``` {r app, echo=TRUE, message=FALSE, warning=FALSE, results="hide", eval = requireNamespace("ggpmics") && requireNamespace("ggExtra") && requireNamespace("colourpicker") }
6868# configuration for the single wide datasets
6969mod1 <- tm_g_scatterplot(
7070 label = "Single wide dataset",
@@ -381,7 +381,7 @@ shinyApp(app$ui, app$server, options = list(height = 1024, width = 1024))
381381
382382## 5 - Try it out in Shinylive
383383
384- ``` {r shinylive_url, echo = FALSE, results = 'asis'}
384+ ``` {r shinylive_url, echo = FALSE, results = 'asis', eval = requireNamespace("roxy.shinylive") }
385385code <- paste0(c(
386386 knitr::knit_code$get("library"),
387387 knitr::knit_code$get("data"),
0 commit comments