On {scdrake} load or attach (?), several environment variables are read and corresponding options() are set. Those are mainly variables controlling paths to config directories. See get_scdrake_options() for more details and list of used environment variables.

We can take the SCDRAKE_SINGLE_SAMPLE_CONFIG_DIR environment variable as an example:


Environment variables are mainly used in _drake_single_sample.R and _drake_integration.R scripts. Those are scripts sourced by {drake} in a fresh new R session via {callr} when you call e.g. run_single_sample_r(). For this reason, environment variables are the only way how to pass dynamic parameters into such scripts. In case of {scdrake}, the most important are paths to directories with config files, which carry analysis/pipeline-specific parameters.



bioinfocz/scdrake documentation built on Sept. 19, 2024, 4:43 p.m.