Create a project object from data spec objects
yspec objects or file names of yaml specification files
the name and path where the project file is to be written
optional data path
used to update SETUP__
block data items
optional project sponsor
optional project number in ...
if TRUE
, then the specification data is saved in the
meta space of the project object
directory containing the specification files if listed
an object of class yproj
Note that sponsor
and projectnumber
can be updated upon creating the
project object. Other document-specific attributes (like title,
author, date) can be specified through ys_document.
where <- system.file("spec", package = "yspec")
files <- file.path(where, c("DEM104101F_PK.yml", "DEM104101F_AE.yml"))
proj <- ys_project(ys_load(files[1]),ys_load(files[2]), sponsor="CompanyX")
proj <- ys_project_file(files[1], files[2], dots = list(projectnumber = "ZZZzzz"))
proj
#> projectnumber: ZZZzzz
#> sponsor: ABC-Pharma
#> --------------------------------------------
#> datafiles:
#> name description data_stem
#> DEM104101F_PK Population PK analysis data set DEM104101F_PK
#> DEM104101F_AE AE analysis data set DEM0104101F_AE_2