From fa6d0d143286ca420efb9dfdde23eba5a04fc919 Mon Sep 17 00:00:00 2001 From: Nazmus Salehin Date: Wed, 28 Feb 2024 18:37:48 -0500 Subject: [PATCH 1/3] Updated skeleton.RMD with data checks for data_version,branch_name, sha and data_hash --- .../templates/visc_report/skeleton/skeleton.Rmd | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd b/inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd index 45d7922a..c8e41193 100644 --- a/inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd +++ b/inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd @@ -103,14 +103,25 @@ pandoc_markup <- set_pandoc_markup(output_type) remotes::install_github("https://github.com/FredHutch/VDCNNNAnalysis.git") ``` +```{r check_data_version} +DataPackageR::assert_data_version("VDCNNNAnalysis",version_string = "data_version") +testthat::expect_equal(packageDescription("VDCNNNAnalysis")$RemoteSha,"commit_sha") +testthat::expect_equal(packageDescription("VDCNNNAnalysis")$RemoteRef,"branch_name") + +``` + + ```{r data-processing} # For this template use VISCfunction example data data(exampleData_ICS) +testthat::expect_equal(digest::digest(exampleData_ICS),"data_hash") + ICS_adata <- exampleData_ICS %>% filter(Population == "IFNg" & Group != 3) ``` + `r insert_break()` # Summary of Main Results From 0d53b21ae3eecceb1176a31c5167ec224dc97858 Mon Sep 17 00:00:00 2001 From: Valeria Duran <106105256+valduran18@users.noreply.github.com> Date: Wed, 28 Feb 2024 17:49:28 -0600 Subject: [PATCH 2/3] add data hash and datapackage branch name to reproducibility table --- .../templates/visc_report/skeleton/skeleton.Rmd | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd b/inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd index c8e41193..e0ec6a6d 100644 --- a/inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd +++ b/inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd @@ -364,8 +364,9 @@ if (any(installed.packages()[,1] == 'rmarkdown')) suppressWarnings(library(rmark my_session_info <- VISCfunctions::get_session_info() -kable( - my_session_info$platform_table, +my_session_info$platform_table %>% + add_row(name = "data hash", value = digest::digest(exampleData_ICS), .before = nrow(.)) %>% + kable( format = output_type, booktabs = TRUE, linesep = "", @@ -375,8 +376,17 @@ kable( ``` ```{r Software-Package-Version-Information, results="asis", warning=kable_warnings} +my_session_info$packages_table %>% + left_join( + sessioninfo::package_info() %>% filter(str_detect(source, pattern = "git2r")) %>% + pull(package) %>% + packageDescription() %>% + .[c("Package","RemoteRef")] %>% + as_tibble() %>% + rename("package" = "Package", + "branch" = "RemoteRef"), + by = "package") %>% kable( - my_session_info$packages_table, format = output_type, booktabs = TRUE, linesep = "", caption = "Reproducibility software package version information" From 410aacc2ddf3905230ecd0c60372f4b0275e1a1a Mon Sep 17 00:00:00 2001 From: Dave Slager Date: Thu, 8 Aug 2024 11:00:25 -0700 Subject: [PATCH 3/3] fix merge commit in one more place --- inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd | 5 ----- 1 file changed, 5 deletions(-) diff --git a/inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd b/inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd index bc9f9eed..d7a19106 100644 --- a/inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd +++ b/inst/rmarkdown/templates/visc_report/skeleton/skeleton.Rmd @@ -135,12 +135,7 @@ ICS_adata <- exampleData_ICS %>% filter(Population == "IFNg" & Group != 3) ``` -<<<<<<< HEAD - -`r insert_break()` -======= `r insert_break()` ->>>>>>> develop # Summary of Main Results