build_path_from_model.RdBuilds the absolute path to a file in the output directory from components of the bbi_{.model_type}_model object
build_path_from_model(.mod, .suffix, ...)
# S3 method for bbi_model
build_path_from_model(.mod, .suffix, ...)Model to use, either a bbi_{.model_type}_model or bbi_{.model_type}_summary object.
Character vector to append the end of the absolute model path.
Will be appended as is so, if passing a file extension, be sure to included the leading ".".
See examples.
arguments passed through to methods. (Currently none.)
Returns an absolute path to {output_dir}/{model_id}{.suffix}.
Does not check whether the file exists.
.mod <- read_model(
system.file("model", "nonmem", "basic", "1", package = "bbr")
)
build_path_from_model(.mod, ".lst")
#> [1] "/data/GHE/deployment/deployments/2022-03-22/renv/library/R-4.1/x86_64-pc-linux-gnu/bbr/model/nonmem/basic/1/1.lst"
build_path_from_model(.mod, "-standata.R")
#> [1] "/data/GHE/deployment/deployments/2022-03-22/renv/library/R-4.1/x86_64-pc-linux-gnu/bbr/model/nonmem/basic/1/1-standata.R"