Load a data specification file

ys_load(file, verbose = FALSE, ...)

ys_load_file(file, data_path = NULL, data_stem = NULL, verbose = FALSE, ...)

load_spec(...)

Arguments

file

Name of yaml file containing specification.

verbose

Logical: print information to the console as the file is processed.

...

Other arguments to update SETUP__.

data_path

Optional path to data sets.

data_stem

Optional alternate stem for data files.

Examples


sp <- ys_load(ys_help$file())
sp
#>  name  info unit         short                         source       
#>  C     cd-  .            comment character             ysdb_internal
#>  NUM   ---  .            record number                 ysdb_internal
#>  ID    ---  .            subject identifier            ysdb_internal
#>  SUBJ  c--  .            subject identifier            ysdb_internal
#>  TIME  ---  hour         TIME                          look         
#>  SEQ   -d-  .            SEQ                           .            
#>  CMT   ---  .            compartment number            ysdb_internal
#>  EVID  -d-  .            event ID                      ysdb_internal
#>  AMT   ---  mg           dose amount                   ysdb_internal
#>  DV    ---  micrograms/L dependent variable            ysdb_internal
#>  AGE   ---  years        age                           ysdb_internal
#>  WT    ---  kg           weight                        ysdb_internal
#>  CRCL  ---  ml/min       CRCL                          .            
#>  ALB   ---  g/dL         albumin                       ysdb_internal
#>  BMI   ---  m2/kg        BMI                           ysdb_internal
#>  AAG   ---  mg/dL        alpha-1-acid glycoprotein     .            
#>  SCR   ---  mg/dL        serum creatinine              .            
#>  AST   ---  .            aspartate aminotransferase    .            
#>  ALT   ---  .            alanine aminotransferase      .            
#>  HT    ---  cm           height                        ysdb_internal
#>  CP    -d-  .            Child-Pugh score              look         
#>  TAFD  ---  hours        time after first dose         .            
#>  TAD   ---  hours        time after dose               .            
#>  LDOS  ---  mg           last dose amount              .            
#>  MDV   -d-  .            MDV                           ysdb_internal
#>  BLQ   -d-  .            below limit of quantification .            
#>  PHASE ---  .            study phase indicator         .            
#>  STUDY -d-  .            study number                  .            
#>  RF    cd-  .            renal function stage          .            

sp <- ys_load(ys_help$file(), verbose = TRUE)
#> ~ working on  ...  analysis1.yml 
#>   description ...  Example PopPK analysis data set 
#>   sponsor     ...  example-project 
#>   lookup file ...  look.yml 
#>   lookup file ...  ysdb_internal.yml 
#> ~ working on  ...  ysdb_internal.yml 
#>   description ...  yspec internal column database 
#> ~ working on  ...  look.yml 
#>   description ...  [data set description] 
#> ::::::::::::: ...  :::::::::::::::::::::::::::::: 
#> ~ looking up  ...  ysdb_internal.yml  --->  C 
#> ~ looking up  ...  ysdb_internal.yml  --->  NUM 
#> ~ looking up  ...  ysdb_internal.yml  --->  ID 
#> ~ looking up  ...  ysdb_internal.yml  --->  SUBJ 
#> ~ looking up  ...  look.yml  --->  TIME 
#> ~ looking up  ...  ysdb_internal.yml  --->  CMT 
#> ~ looking up  ...  ysdb_internal.yml  --->  EVID 
#> ~ looking up  ...  ysdb_internal.yml  --->  AMT 
#> ~ looking up  ...  ysdb_internal.yml  --->  DV 
#> ~ looking up  ...  ysdb_internal.yml  --->  AGE 
#> ~ looking up  ...  ysdb_internal.yml  --->  WT 
#> ~ looking up  ...  ysdb_internal.yml  --->  ALB 
#> ~ looking up  ...  ysdb_internal.yml  --->  BMI 
#> ~ looking up  ...  ysdb_internal.yml  --->  HT 
#> ~ looking up  ...  look.yml  --->  CP 
#> ~ looking up  ...  ysdb_internal.yml  --->  MDV