plan
Turns a named collection of command/target pairs into
a workflow plan data frame for make
and
check
. Deprecated in favor of
workplan()
due to a name conflict with
future::plan()
.
plan(..., list = character(0), file_targets = FALSE,
strings_in_dots = c("filenames", "literals"))
commands named by the targets they generate.
Recall that drake uses single quotes to denote external files
and double-quoted strings as ordinary strings.
Use the strings_in_dots
argument to control the
quoting in ...
.
character vector of commands named by the targets they generate.
logical. If TRUE
, targets are single-quoted
to tell drake that these are external files that should be expected
as output in the next call to make()
.
character scalar. If "filenames"
,
all character strings in ...
will be treated as names of file
dependencies (single-quoted). If "literals"
, all
character strings in ...
will be treated as ordinary
strings, not dependencies of any sort (double-quoted).
Because of R's automatic parsing/deparsing behavior,
strings in ...
cannot simply be left alone.
data frame of targets and command
# NOT RUN {
# plan() is deprecated. Use workplan() instead.
workplan(small = simulate(5), large = simulate(50))
workplan(list = c(x = "1 + 1", y = "sqrt(x)"))
workplan(data = readRDS("my_data.rds"))
workplan(
my_file.rds = saveRDS(1+1, "my_file.rds"),
file_targets = TRUE,
strings_in_dots = "literals"
)
# }
Run the code above in your browser using DataLab