diff --git a/DESCRIPTION b/DESCRIPTION
index f0e9034..78999a7 100644
--- a/DESCRIPTION
+++ b/DESCRIPTION
@@ -15,6 +15,8 @@ Authors@R:
role = "aut",
email = "annanev@umich.edu"))
License: MIT + file LICENSE
+URL: https://metrumresearchgroup.github.io/pmforest, https://github.com/metrumresearchgroup/pmforest
+BugReports: https://github.com/metrumresearchgroup/pmforest/issues
Imports:
assertthat,
dplyr,
@@ -34,8 +36,6 @@ Imports:
Suggests:
devtools,
knitr,
- mrgvalidate,
- mrgvalprep (>= 0.0.4),
svglite,
testthat (>= 3.0.0),
vdiffr,
@@ -48,13 +48,4 @@ Encoding: UTF-8
Roxygen: list(markdown = TRUE)
RoxygenNote: 7.2.3
VignetteBuilder: knitr
-Collate:
- 'classicforest.R'
- 'table-plot.R'
- 'forest-constructor.R'
- 'AAAA.R'
- 'helpers-for-tests.R'
- 'plot-forest.R'
- 'summarize-data.R'
- 'utils-null.R'
- 'utils-pipe.R'
+
diff --git a/R/AAAA.R b/R/AAAA.R
index 48a77ad..c1a7a99 100644
--- a/R/AAAA.R
+++ b/R/AAAA.R
@@ -18,9 +18,6 @@
#' @importFrom stats median quantile
#' @importFrom RColorBrewer brewer.pal
#'
-#' @include forest-constructor.R
-#' @include table-plot.R
-#' @include classicforest.R
#'
NULL
diff --git a/R/utils-null.R b/R/utils-null.R
deleted file mode 100644
index 63991ff..0000000
--- a/R/utils-null.R
+++ /dev/null
@@ -1,14 +0,0 @@
-# if the value of x is null, use y
-# for example, given a val that, if
-# null should be an NA of type character
-# either:
-# `nullable(val, NA_character_)`
-# `val %||% NA_character_`
-nullable <- function(x, y) {
- if (is.null(x)) {
- return(y)
- }
- return(x)
-}
-
-`%||%` <- nullable
diff --git a/inst/validation/.gitignore b/inst/validation/.gitignore
deleted file mode 100644
index 1a1dc4c..0000000
--- a/inst/validation/.gitignore
+++ /dev/null
@@ -1,5 +0,0 @@
-*.html
-*.docx
-*.pdf
-*.md
-test_results/
diff --git a/inst/validation/build-validation-docs.R b/inst/validation/build-validation-docs.R
deleted file mode 100644
index 23e248c..0000000
--- a/inst/validation/build-validation-docs.R
+++ /dev/null
@@ -1,66 +0,0 @@
-#######################################################
-## This script runs the test suite and builds
-## the validation documents from the test outputs
-##
-## The script expects the following:
-## * Validation stories in mrgvalprep YAML format in "inst/validation/{PKGNAME}-stories.yaml"
-## * A standard testthat test suite than can be run with devtools::test()
-##
-## It will write the validation documents to
-## "inst/validation/{PKGNAME}-{PKGVERSION}-validation-docs/")
-##
-#######################################################
-
-PKGNAME <- "pmforest"
-PKGVERSION <- "0.0.1"
-STYLE_REF_DIR <- "docx-ref-header-image" # set to NULL if not using style ref
-
-# set up directories and clear existing output dirs, if they exist
-val_dir <- system.file("validation", package = PKGNAME)
-print(val_dir)
-
-style_ref_path <- NULL
-if (!is.null(STYLE_REF_DIR)) {
- style_ref_path <- file.path(val_dir, STYLE_REF_DIR)
-}
-
-test_dir <- file.path(val_dir, "test_results")
-if (fs::dir_exists(test_dir)) fs::dir_delete(test_dir)
-fs::dir_create(test_dir)
-
-docs_dir <- file.path(val_dir, paste0(PKGNAME, "-", PKGVERSION, "-validation-docs"))
-if (fs::dir_exists(docs_dir)) fs::dir_delete(docs_dir)
-fs::dir_create(docs_dir)
-
-# run tests and write res to disk
-test_res <- mrgvalprep::parse_testthat_list_reporter(
- devtools::test(Reporter = testthat::ListReporter),
- roll_up_ids = TRUE
-)
-
-write.csv(
- test_res,
- file.path(test_dir, paste0(PKGNAME, "-tests.csv"))
-)
-
-# capture commit hash and other system info
-git_hash <- system("git rev-parse HEAD", intern=TRUE)
-Sys.setenv("COMMIT_HASH" = git_hash)
-
-mrgvalprep::get_sys_info(
- out_path = file.path(test_dir, paste0(PKGNAME, "-tests.json")),
- env_vars = c("METWORX_VERSION", "COMMIT_HASH")
-)
-
-# read in stories
-spec <- mrgvalprep::read_spec_yaml(file.path(val_dir, paste0(PKGNAME, "-stories.yaml")))
-
-# make docs
-mrgvalidate::create_validation_docs(
- PKGNAME,
- PKGVERSION,
- spec,
- auto_test_dir = test_dir,
- output_dir = docs_dir,
- style_dir = style_ref_path
-)
diff --git a/inst/validation/pmforest-stories.yaml b/inst/validation/pmforest-stories.yaml
deleted file mode 100644
index 4a82bcd..0000000
--- a/inst/validation/pmforest-stories.yaml
+++ /dev/null
@@ -1,126 +0,0 @@
-PLOT-S001:
- name: Create basic forest plot
- description: As a user, I want to be able to generate forest plots using previously-simulated
- data for a model with various covariates set to fixed values, so that I can evaluate
- the potential for effects of covariates on model properties.
- ProductRisk: high
- tests:
- - PMF-PLOT-017
- - PMF-PLOT-018
-DATA-S001:
- name: summary methods
- description: As a user, I want to be able to specify the type of summaries presented
- for each covariate level in the forest plot, including the location type (mean
- vs median) and width of the confidence interval (e.g., 90% vs 95%).
- ProductRisk: high
- tests:
- - PMF-DATA-001
- - PMF-DATA-002
- - PMF-DATA-003
-PLOT-S004:
- name: metagroup specification
- description: As a user, I want to be able to generate multiple forest plots from
- the same set of simulations, e.g., for multiple model parameters (CL and V) or
- multiple responses (AUC and Cmax) or a combination of both (CL, AUC, Cmax).
- ProductRisk: low
- tests:
- - PMF-PLOT-004
- - PMF-PLOT-005
-PLOT-S005:
- name: CI table
- description: As a user, I would like each plot to optionally include accompanying
- text showing the location (mean/median) and CI for each covariate level.
- ProductRisk: high
- tests:
- - PMF-PLOT-006
- - PMF-PLOT-007
-PLOT-S006:
- name: Plot/table width
- description: As a user, I would like to be able to specify the relative widths of
- the plot and accompanying text.
- ProductRisk: low
- tests: PMF-PLOT-008
-PLOT-S007:
- name: Set vertical intercept
- description: As a user, I would like the forest plots to show a vertical line at
- a specified value to show the reference value for comparison.
- ProductRisk: medium
- tests: PMF-PLOT-009
-PLOT-S008:
- name: shaded interval
- description: As a user, I would like to have the option to include a shaded interval
- for the value being plotted, for the range that I specify.
- ProductRisk: medium
- tests: PMF-PLOT-010
-PLOT-S009:
- name: update labels via yaml file
- description: As a user, I would like to be able to provide custom labels for the
- covariates and response/parameter.
- ProductRisk: low
- tests: PMF-PLOT-011
-PLOT-S010:
- name: plot multiple simulations
- description: As a user, I would like to be able to (when providing data from nested
- simulations) have the forest plots reflect the variability between replicates
- by showing additional confidence interval line segments above the overall values
- (i.e., above the mean/median and upper/lower percentiles).
- ProductRisk: high
- tests:
- - PMF-PLOT-012
- - PMF-PLOT-013
-PLOT-S011:
- name: label adjustments and positioning
- description: As a user, I would like to have control over axis labels, breaks, and
- limits, as well as text size for all text elements.
- ProductRisk: medium
- tests:
- - PMF-PLOT-014
- - PMF-PLOT-015
- - PMF-PLOT-016
- - PMF-PLOT-023
-PLOT-S012:
- name: Formatting options, ggplot themes
- description: As a user, I would like to have be able to change the shape and size
- of the median value. I would also like to modify the default ggplot theme.
- ProductRisk: medium
- tests:
- - PMF-PLOT-020
- - PMF-PLOT-021
- - PMF-PLOT-022
-DATA-S002:
- name: Column selection, summary
- description: As a user, I want to be able to specify which model property (i.e.,
- predicted response (e.g., AUC or Cmax) or parameter value (e.g., CL or V)) will
- be summarized in the forest plot.
- ProductRisk: high
- tests:
- - PMF-DATA-001
- - PMF-DATA-003
-DATA-S003:
- name: Summarize data by group
- description: As a user, I want to pass in raw data and summarize by group, and optionally
- level and metagroup.
- ProductRisk: high
- tests:
- - PMF-DATA-001
- - PMF-DATA-002
- - PMF-PLOT-019
- - PMF-PLOT-024
-DATA-S004:
- name: Summarize across replicates
- description: As a user, I want to calculate median, lower, and upper quantile, for
- each replicate and optionally across multiple replicates.
- ProductRisk: high
- tests: PMF-DATA-003
-DATA-S005:
- name: Control significant digits
- description: As a user, I want to be able specify the number of significant digits
- for my summary statistics, and control whether to use scientific or numeric notation.
- ProductRisk: low
- tests: PMF-PLOT-018
-DATA-S006:
- name: Check input data
- description: As a user, I want to be notified if I do not have the required input
- data for plotting.
- ProductRisk: low
- tests: PMF-DATA-004
diff --git a/pkgr.yml b/pkgr.yml
index e705a6c..aa4d129 100644
--- a/pkgr.yml
+++ b/pkgr.yml
@@ -11,7 +11,7 @@ Packages:
Repos:
- CRAN: https://cran.rstudio.com # used for most things
- - MPN: https://mpn.metworx.com/snapshots/stable/2022-02-11 # used for pmtables and mrgval
+ - MPN: https://mpn.metworx.com/snapshots/stable/2023-08-24 # used for specific Metrum packages (such as pmtables & yspec)
Lockfile:
Type: renv
diff --git a/tests/testthat/_snaps/base-plot/axis-labels-and-captions.svg b/tests/testthat/_snaps/base-plot/axis-labels-and-captions.svg
index 0158b33..1ed199e 100644
--- a/tests/testthat/_snaps/base-plot/axis-labels-and-captions.svg
+++ b/tests/testthat/_snaps/base-plot/axis-labels-and-captions.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/base-plot.svg b/tests/testthat/_snaps/base-plot/base-plot.svg
index 04b1969..a34753a 100644
--- a/tests/testthat/_snaps/base-plot/base-plot.svg
+++ b/tests/testthat/_snaps/base-plot/base-plot.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/change-ci-interval-format-change-both.svg b/tests/testthat/_snaps/base-plot/change-ci-interval-format-change-both.svg
index 3c2dda5..cc9f17b 100644
--- a/tests/testthat/_snaps/base-plot/change-ci-interval-format-change-both.svg
+++ b/tests/testthat/_snaps/base-plot/change-ci-interval-format-change-both.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/change-ci-interval-format-mixed.svg b/tests/testthat/_snaps/base-plot/change-ci-interval-format-mixed.svg
index 610fb98..0935249 100644
--- a/tests/testthat/_snaps/base-plot/change-ci-interval-format-mixed.svg
+++ b/tests/testthat/_snaps/base-plot/change-ci-interval-format-mixed.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/character-interpretation-of-numeric-group-level.svg b/tests/testthat/_snaps/base-plot/character-interpretation-of-numeric-group-level.svg
index bd8d8ec..4d9f180 100644
--- a/tests/testthat/_snaps/base-plot/character-interpretation-of-numeric-group-level.svg
+++ b/tests/testthat/_snaps/base-plot/character-interpretation-of-numeric-group-level.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/ci-table-mean.svg b/tests/testthat/_snaps/base-plot/ci-table-mean.svg
index 31f98d3..064e33a 100644
--- a/tests/testthat/_snaps/base-plot/ci-table-mean.svg
+++ b/tests/testthat/_snaps/base-plot/ci-table-mean.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/ci-table-median.svg b/tests/testthat/_snaps/base-plot/ci-table-median.svg
index 2c3457f..85f4627 100644
--- a/tests/testthat/_snaps/base-plot/ci-table-median.svg
+++ b/tests/testthat/_snaps/base-plot/ci-table-median.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/full-test-big.svg b/tests/testthat/_snaps/base-plot/full-test-big.svg
index 819b90e..df69f63 100644
--- a/tests/testthat/_snaps/base-plot/full-test-big.svg
+++ b/tests/testthat/_snaps/base-plot/full-test-big.svg
@@ -24,46 +24,54 @@
-
-
+
+
-
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
+
+
-
+
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -79,38 +87,38 @@
-
-
-
-
-
-
+
+
+
+
+
+
-
-
-
+
+
+
-
-
-
-
+
+
+
+
-
+
-
+
Weight
85 kg
55 kg
Renal Function
Severe
-Moderate
+Moderate
Mild
Albumin
5 g/dL
@@ -121,8 +129,8 @@
-
-
+
+
@@ -130,14 +138,14 @@
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
0.4
0.6
0.8
@@ -145,31 +153,31 @@
1.2
1.4
Fraction and 95% CI
-Relative to Reference
+Relative to Reference
CL (L/hr)
-
-
+
+
-
-
+
+
-
+
-
+
Weight
1.2 [1.2, 1.2]
0.83 [0.83, 0.83]
-Renal Function
-0.51 [0.47, 0.56]
+Renal Function
+0.51 [0.47, 0.56]
0.70 [0.66, 0.73]
0.92 [0.90, 0.93]
Albumin
@@ -177,20 +185,20 @@
0.87 [0.84, 0.90]
Age
0.99 [0.96, 1.0]
-1.0 [0.97, 1.1]
-
+1.0 [0.97, 1.1]
+
-
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
1.0
1.1
1.2
diff --git a/tests/testthat/_snaps/base-plot/full-test-small.svg b/tests/testthat/_snaps/base-plot/full-test-small.svg
index 1367d8f..e99bf79 100644
--- a/tests/testthat/_snaps/base-plot/full-test-small.svg
+++ b/tests/testthat/_snaps/base-plot/full-test-small.svg
@@ -24,51 +24,59 @@
-
-
+
+
-
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
+
+
-
+
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
@@ -89,7 +97,7 @@
-
+
@@ -104,20 +112,20 @@
-
+
Weight
85 kg
55 kg
Renal Function
-Severe
+Severe
Moderate
Mild
Albumin
-5 g/dL
+5 g/dL
3.25 g/dL
-Age
+Age
45 years
-20 years
+20 years
@@ -131,13 +139,13 @@
-
-
-
-
-
-
-
+
+
+
+
+
+
+
0.4
0.6
0.8
@@ -145,25 +153,25 @@
1.2
1.4
Fraction and 95% CI
-Relative to Reference
+Relative to Reference
CL (L/hr)
-
-
+
+
-
-
+
+
-
+
-
+
Weight
1.2 [1.2, 1.2]
@@ -178,19 +186,19 @@
Age
0.99 [0.96, 1.0]
1.0 [0.97, 1.1]
-
+
-
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
1.0
1.1
1.2
diff --git a/tests/testthat/_snaps/base-plot/full-test.svg b/tests/testthat/_snaps/base-plot/full-test.svg
index 357aa5a..6758005 100644
--- a/tests/testthat/_snaps/base-plot/full-test.svg
+++ b/tests/testthat/_snaps/base-plot/full-test.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/modify-ggplot-theme.svg b/tests/testthat/_snaps/base-plot/modify-ggplot-theme.svg
index 80d72ff..1e4d151 100644
--- a/tests/testthat/_snaps/base-plot/modify-ggplot-theme.svg
+++ b/tests/testthat/_snaps/base-plot/modify-ggplot-theme.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/modify-shape-size.svg b/tests/testthat/_snaps/base-plot/modify-shape-size.svg
index 0f7d7d3..802b325 100644
--- a/tests/testthat/_snaps/base-plot/modify-shape-size.svg
+++ b/tests/testthat/_snaps/base-plot/modify-shape-size.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/modify-shape.svg b/tests/testthat/_snaps/base-plot/modify-shape.svg
index 0b6a744..185b4cd 100644
--- a/tests/testthat/_snaps/base-plot/modify-shape.svg
+++ b/tests/testthat/_snaps/base-plot/modify-shape.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/modify-text-size.svg b/tests/testthat/_snaps/base-plot/modify-text-size.svg
index 336fa56..8a48b09 100644
--- a/tests/testthat/_snaps/base-plot/modify-text-size.svg
+++ b/tests/testthat/_snaps/base-plot/modify-text-size.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/multiple-lines-for-ci-label.svg b/tests/testthat/_snaps/base-plot/multiple-lines-for-ci-label.svg
index 40d7d29..eff1d03 100644
--- a/tests/testthat/_snaps/base-plot/multiple-lines-for-ci-label.svg
+++ b/tests/testthat/_snaps/base-plot/multiple-lines-for-ci-label.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/no-group-level.svg b/tests/testthat/_snaps/base-plot/no-group-level.svg
index 35935ef..8845220 100644
--- a/tests/testthat/_snaps/base-plot/no-group-level.svg
+++ b/tests/testthat/_snaps/base-plot/no-group-level.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/numeric-group-level.svg b/tests/testthat/_snaps/base-plot/numeric-group-level.svg
index 844c5e4..fbafc39 100644
--- a/tests/testthat/_snaps/base-plot/numeric-group-level.svg
+++ b/tests/testthat/_snaps/base-plot/numeric-group-level.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/plot-table-width.svg b/tests/testthat/_snaps/base-plot/plot-table-width.svg
index 48bf584..33b0d2b 100644
--- a/tests/testthat/_snaps/base-plot/plot-table-width.svg
+++ b/tests/testthat/_snaps/base-plot/plot-table-width.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/shaded-interval.svg b/tests/testthat/_snaps/base-plot/shaded-interval.svg
index 89098ac..72acf3b 100644
--- a/tests/testthat/_snaps/base-plot/shaded-interval.svg
+++ b/tests/testthat/_snaps/base-plot/shaded-interval.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/test-breaks-and-limits-of-x-axis.svg b/tests/testthat/_snaps/base-plot/test-breaks-and-limits-of-x-axis.svg
index efd1914..42a0622 100644
--- a/tests/testthat/_snaps/base-plot/test-breaks-and-limits-of-x-axis.svg
+++ b/tests/testthat/_snaps/base-plot/test-breaks-and-limits-of-x-axis.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/test-metagroup-with-labels.svg b/tests/testthat/_snaps/base-plot/test-metagroup-with-labels.svg
index 5697d8c..a1dedc7 100644
--- a/tests/testthat/_snaps/base-plot/test-metagroup-with-labels.svg
+++ b/tests/testthat/_snaps/base-plot/test-metagroup-with-labels.svg
@@ -20,6 +20,15 @@
+
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/test-metagroup-with-nrow.svg b/tests/testthat/_snaps/base-plot/test-metagroup-with-nrow.svg
index 9af0811..cdd091b 100644
--- a/tests/testthat/_snaps/base-plot/test-metagroup-with-nrow.svg
+++ b/tests/testthat/_snaps/base-plot/test-metagroup-with-nrow.svg
@@ -20,6 +20,15 @@
+
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/test-metagroup.svg b/tests/testthat/_snaps/base-plot/test-metagroup.svg
index ba195c8..d0c75bc 100644
--- a/tests/testthat/_snaps/base-plot/test-metagroup.svg
+++ b/tests/testthat/_snaps/base-plot/test-metagroup.svg
@@ -20,6 +20,15 @@
+
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/update-labels-via-yaml-file.svg b/tests/testthat/_snaps/base-plot/update-labels-via-yaml-file.svg
index 6cd89d0..290af94 100644
--- a/tests/testthat/_snaps/base-plot/update-labels-via-yaml-file.svg
+++ b/tests/testthat/_snaps/base-plot/update-labels-via-yaml-file.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/base-plot/vertical-intercept.svg b/tests/testthat/_snaps/base-plot/vertical-intercept.svg
index 826698d..a69b926 100644
--- a/tests/testthat/_snaps/base-plot/vertical-intercept.svg
+++ b/tests/testthat/_snaps/base-plot/vertical-intercept.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/nsim-plot/multiple-ci-s-with-jitter.svg b/tests/testthat/_snaps/nsim-plot/multiple-ci-s-with-jitter.svg
index b534769..fe7501c 100644
--- a/tests/testthat/_snaps/nsim-plot/multiple-ci-s-with-jitter.svg
+++ b/tests/testthat/_snaps/nsim-plot/multiple-ci-s-with-jitter.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/_snaps/nsim-plot/multiple-simulations.svg b/tests/testthat/_snaps/nsim-plot/multiple-simulations.svg
index 2e75e46..d7492b0 100644
--- a/tests/testthat/_snaps/nsim-plot/multiple-simulations.svg
+++ b/tests/testthat/_snaps/nsim-plot/multiple-simulations.svg
@@ -29,6 +29,14 @@
+
+
+
+
+
+
+
+
diff --git a/tests/testthat/test-base-plot.R b/tests/testthat/test-base-plot.R
index 3346b84..e1095f6 100644
--- a/tests/testthat/test-base-plot.R
+++ b/tests/testthat/test-base-plot.R
@@ -31,7 +31,7 @@ describe("Base plots", {
group_level = LVL
)
- it("Test metagroup (Cl and V2) [PMF-PLOT-004]", {
+ it("Test metagroup (Cl and V2)", {
skip_on_cran()
skip_vdiffr()
plt1 <- sumData2 %>%
@@ -45,7 +45,7 @@ describe("Base plots", {
})
- it("Test metagroup (Cl and V2) with labels [PMF-PLOT-005]", {
+ it("Test metagroup (Cl and V2) with labels", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData2,
@@ -56,7 +56,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("Test metagroup with labels", plt)
})
- it("CI Table - mean [PMF-PLOT-006]", {
+ it("CI Table - mean", {
skip_on_cran()
skip_vdiffr()
plt <- plotData %>%
@@ -72,7 +72,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("CI Table - mean", plt)
})
- it("CI Table - median [PMF-PLOT-007]", {
+ it("CI Table - median", {
skip_on_cran()
skip_vdiffr()
plt <- plotData %>%
@@ -88,7 +88,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("CI Table - median", plt)
})
- it("Plot/Table width [PMF-PLOT-008]", {
+ it("Plot/Table width", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData,
@@ -97,7 +97,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("Plot/Table width", plt)
})
- it("Vertical Intercept [PMF-PLOT-009]", {
+ it("Vertical Intercept", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData,
@@ -106,7 +106,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("Vertical Intercept", plt)
})
- it("shaded interval displays over correct range [PMF-PLOT-010]", {
+ it("shaded interval displays over correct range", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData,
@@ -115,7 +115,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("shaded interval", plt)
})
- it("update labels via yaml file [PMF-PLOT-011]", {
+ it("update labels via yaml file", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData,
@@ -124,7 +124,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("update labels via yaml file", plt)
})
- it("Axis labels and captions [PMF-PLOT-014]", {
+ it("Axis labels and captions", {
skip_on_cran()
skip_vdiffr()
plt <- plotData %>%
@@ -142,7 +142,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("Axis labels and captions", plt)
})
- it("Test breaks and limits of x-axis [PMF-PLOT-015]", {
+ it("Test breaks and limits of x-axis", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData,
@@ -153,7 +153,7 @@ describe("Base plots", {
})
- it("Modify text size [PMF-PLOT-016]", {
+ it("Modify text size", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData,
@@ -162,7 +162,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("Modify text size", plt)
})
- it("Base plot [PMF-PLOT-017]", {
+ it("Base plot", {
skip_on_cran()
skip_vdiffr()
plt <- plotData %>%
@@ -175,7 +175,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("Base plot", plt)
})
- it("Full Test [PMF-PLOT-018]", {
+ it("Full Test", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData,
@@ -198,7 +198,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("Full Test", plt)
})
- it("plots without group_level [PMF-PLOT-019]", {
+ it("plots without group_level", {
skip_on_cran()
skip_vdiffr()
df <-
@@ -212,7 +212,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("No group_level", plt)
})
- it("modify shape of median value [PMF-PLOT-020]", {
+ it("modify shape of median value", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData,
@@ -221,7 +221,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("Modify shape", plt)
})
- it("modify shape size of median value [PMF-PLOT-021]", {
+ it("modify shape size of median value", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData,
@@ -230,7 +230,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("Modify shape size", plt)
})
- it("modify ggplot theme [PMF-PLOT-022]", {
+ it("modify ggplot theme", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData,
@@ -239,7 +239,7 @@ describe("Base plots", {
vdiffr::expect_doppelganger("Modify ggplot theme", plt)
})
- it("Multiple lines for CI_label [PMF-PLOT-023]", {
+ it("Multiple lines for CI_label", {
skip_on_cran()
skip_vdiffr()
expect_error(
@@ -254,7 +254,7 @@ describe("Base plots", {
})
- it("Plot alignment with different saving to different sizes [PMF-PLOT-024]", {
+ it("Plot alignment with different saving to different sizes", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData,
@@ -286,7 +286,7 @@ describe("Base plots", {
})
- it("group_level works with numeric data [PMF-PLOT-024]", {
+ it("group_level works with numeric data", {
skip_on_cran()
skip_vdiffr()
df <- plotData %>%
@@ -309,7 +309,7 @@ describe("Base plots", {
})
- it("Change CI interval format [PMF-PLOT-025]", {
+ it("Change CI interval format", {
skip_on_cran()
skip_vdiffr()
plt <- plot_forest(data = sumData,
diff --git a/tests/testthat/test-input-data.R b/tests/testthat/test-input-data.R
index 421b85a..7e82395 100644
--- a/tests/testthat/test-input-data.R
+++ b/tests/testthat/test-input-data.R
@@ -1,4 +1,4 @@
-test_that("plot_forest() input data check errors with missing value column [PMF-DATA-004]", {
+test_that("plot_forest() input data check errors with missing value column", {
df <-
data.frame(
group = c("a", "b", "c"),
@@ -11,7 +11,7 @@ test_that("plot_forest() input data check errors with missing value column [PMF-
)
})
-test_that("plot_forest() input data check errors with missing group column [PMF-DATA-004]", {
+test_that("plot_forest() input data check errors with missing group column", {
df <-
data.frame(
lo = c(1, 2, 3),
@@ -24,7 +24,7 @@ test_that("plot_forest() input data check errors with missing group column [PMF-
)
})
-test_that("plot_forest() input data check warns with extra columns [PMF-DATA-004]", {
+test_that("plot_forest() input data check warns with extra columns", {
df <-
data.frame(
group = c("a", "b", "c"),
diff --git a/tests/testthat/test-nsim-plot.R b/tests/testthat/test-nsim-plot.R
index 72ffe49..cb59503 100644
--- a/tests/testthat/test-nsim-plot.R
+++ b/tests/testthat/test-nsim-plot.R
@@ -17,7 +17,7 @@ describe("Multiple simulations", {
plotData2 <- readRDS(file.path(dataDir, "plotDataEXP.RDS")) %>%
mutate(stat = stat + (nsim/300)) # make larger to test jitter
- it("Multiple simulations base test [PMF-PLOT-012]", {
+ it("Multiple simulations base test", {
skip_on_cran()
skip_vdiffr()
plt <- plotData %>%
@@ -39,7 +39,7 @@ describe("Multiple simulations", {
vdiffr::expect_doppelganger("Multiple simulations", plt)
})
- it("Multiple CI's with jitter [PMF-PLOT-013]", {
+ it("Multiple CI's with jitter", {
skip_on_cran()
skip_vdiffr()
plt <- plotData2 %>%
diff --git a/tests/testthat/test-summary.R b/tests/testthat/test-summary.R
index 2d1c59c..11b41a1 100644
--- a/tests/testthat/test-summary.R
+++ b/tests/testthat/test-summary.R
@@ -31,18 +31,18 @@ describe("Column selection, summary", {
lo = quantile(stat, lci),
hi = quantile(stat, uci))
- it("correct column is summarized [PMF-DATA-001]", {
+ it("correct column is summarized", {
expect_equal(sumdat_med$lo, sumdat$lo) # test lower quartile
expect_equal(sumdat_med$hi, sumdat$hi) # test upper quartile
})
- it("Can switch between mean/median [PMF-DATA-002]", {
+ it("Can switch between mean/median", {
expect_equal(sumdat_med$mid, sumdat$med) # Test medians
expect_equal(sumdat_mn$mid, sumdat$mean) # Test means
})
- it("Summary for multiple CI's [PMF-DATA-003]", {
+ it("Summary for multiple CI's", {
sumdat_med <- summarize_data(
plotData2,