
Source R Scripts from improve Repository
sourceR.RdDownloads and sources R scripts stored in the improve repository. If the target is a folder or list of resources, the function recursively sources each script.
Usage
sourceR(ident, from = pwd(), addAsLink = TRUE)Arguments
- ident
Path, resource ID, or entity ID of the R script.
- from
Root path for resolving relative paths. Defaults to
pwd().- addAsLink
Logical. If
TRUE, creates a link in the inventory for provenance tracking. UseimproveClean()at workflow end to clean up links.
Details
This function wraps getR to download the script, then calls
source() on the local file path. When multiple resources are returned,
each is sourced in sequence. Sourcing executes code in the current session, so
ensure the script content is trusted and compatible with your environment.
See also
getR to download scripts or RDS metadata,
improveInit for module initialization