From 9c4afb5e928d14d4ddf198172e91e25e20a27536 Mon Sep 17 00:00:00 2001 From: Milan Wiedemann Date: Tue, 19 Nov 2024 14:26:11 +0000 Subject: [PATCH] Add Shiny App as vignette --- .Rbuildignore | 4 +++- .gitignore | 3 +++ DESCRIPTION | 3 +++ README.Rmd | 4 +++- README.md | 8 ++++++-- vignettes/.gitignore | 2 ++ vignettes/code_usage_explorer.Rmd | 28 ++++++++++++++++++++++++++++ 7 files changed, 48 insertions(+), 4 deletions(-) create mode 100644 vignettes/.gitignore create mode 100644 vignettes/code_usage_explorer.Rmd diff --git a/.Rbuildignore b/.Rbuildignore index 65b639f..38800f6 100644 --- a/.Rbuildignore +++ b/.Rbuildignore @@ -8,4 +8,6 @@ ^docs$ ^pkgdown$ ^app.R$ -^rsconnect$ \ No newline at end of file +^rsconnect$ +^doc$ +^Meta$ diff --git a/.gitignore b/.gitignore index 989a496..5b735cd 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,6 @@ docs rsconnect/ .DS_Store +inst/doc +/doc/ +/Meta/ diff --git a/DESCRIPTION b/DESCRIPTION index be3ca17..a24650d 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -20,6 +20,8 @@ Depends: LazyData: true LazyDataCompression: bzip2 Suggests: + knitr, + rmarkdown, testthat (>= 3.0.0) Config/testthat/edition: 3 URL: https://github.com/ebmdatalab/codeusage, https://ebmdatalab.github.io/codeusage/ @@ -41,3 +43,4 @@ Imports: shiny, stringr, tibble +VignetteBuilder: knitr diff --git a/README.Rmd b/README.Rmd index 72f3d23..b571bf9 100644 --- a/README.Rmd +++ b/README.Rmd @@ -21,7 +21,9 @@ knitr::opts_chunk$set( -The goal of `codeusage` is to make yearly summaries of **SNOMED Code Usage in Primary Care** and **ICD-10 and OPCS Code Usage in Secondary Care** in England, published by NHS Digital, available in R for research. The original data is available from NHS Digital at: +The goal of `codeusage` is to make yearly summaries of **SNOMED Code Usage in Primary Care** and **ICD-10 and OPCS Code Usage in Secondary Care** in England, published by NHS Digital, available in R for research. +The interactive [Code Usage Explorer](https://milanwiedemann.shinyapps.io/codeusage/) dashboard provides different options to explore these datasets. +The original data is available from NHS Digital at: - [SNOMED Code Usage in Primary Care](https://digital.nhs.uk/data-and-information/publications/statistical/mi-snomed-code-usage-in-primary-care) - [ICD-10 and OPCS Code Usage in Secondary Care](https://digital.nhs.uk/data-and-information/publications/statistical/hospital-admitted-patient-care-activity) diff --git a/README.md b/README.md index 6f9a0c1..bcddc98 100644 --- a/README.md +++ b/README.md @@ -9,8 +9,12 @@ -The goal of `codeusage` is to make yearly summaries of **SNOMED CodevUsage in Primary Care** and **ICD-10 and OPCS Code Usage in SecondaryvCare** in England, published by NHS Digital, available in R forvresearch. -The interactive [Code Usage Explorer](https://milanwiedemann.shinyapps.io/codeusage/) app allows users to explore the data online. +The goal of `codeusage` is to make yearly summaries of **SNOMED Code +Usage in Primary Care** and **ICD-10 and OPCS Code Usage in Secondary +Care** in England, published by NHS Digital, available in R for +research. The interactive [Code Usage +Explorer](https://milanwiedemann.shinyapps.io/codeusage/) dashboard +provides different options to explore these datasets. The original data is available from NHS Digital at: - [SNOMED Code Usage in Primary diff --git a/vignettes/.gitignore b/vignettes/.gitignore new file mode 100644 index 0000000..097b241 --- /dev/null +++ b/vignettes/.gitignore @@ -0,0 +1,2 @@ +*.html +*.R diff --git a/vignettes/code_usage_explorer.Rmd b/vignettes/code_usage_explorer.Rmd new file mode 100644 index 0000000..02c570a --- /dev/null +++ b/vignettes/code_usage_explorer.Rmd @@ -0,0 +1,28 @@ +--- +title: "Shiny: Code Usage Explorer" +output: rmarkdown::html_vignette +vignette: > + %\VignetteIndexEntry{shiny_code_usage_explorer} + %\VignetteEngine{knitr::rmarkdown} + %\VignetteEncoding{UTF-8} +--- + + + +
+ +
\ No newline at end of file