Skip to contents

Resolves the registered filename beneath the study's logical datasets directory. The path is not checked for existence.

Usage

built_path(cfg = study_config(), dataset = "study")

Arguments

cfg

List. A study manifest from study_config.

dataset

Character(1). Logical dataset name. Defaults to "study". "built" is a second name for "study".

Value

Character(1). The path to the built dataset.

Examples

root <- file.path(tempdir(), "built-path-example")
dir.create(file.path(root, "datasets"), recursive = TRUE,
           showWarnings = FALSE)
yaml::write_yaml(
  list(study = "Example", built = "example.sas7bdat"),
  file.path(root, "_study.yml")
)
built_path(study_config(root))
#> [1] "/tmp/RtmpAxnHxw/built-path-example/datasets/example.sas7bdat"
unlink(root, recursive = TRUE)