Learn R Programming

drake (version 5.2.1)

read_drake_graph: Read the igraph dependency network from your last attempted call to make().

Description

For more user-friendly graphing utilities, see vis_drake_graph() and related functions.

Usage

read_drake_graph(path = getwd(), search = TRUE, cache = NULL,
  verbose = drake::default_verbose(), ...)

Arguments

path

Root directory of the drake project, or if search is TRUE, either the project root or a subdirectory of the project. Ignored if a cache is supplied.

search

logical. If TRUE, search parent directories to find the nearest drake cache. Otherwise, look in the current working directory only. Ignored if a cache is supplied.

cache

drake cache. See new_cache(). If supplied, path and search are ignored.

verbose

logical or numeric, control printing to the console. Use pkgconfig to set the default value of verbose for your R session: for example, pkgconfig::set_config("drake::verbose" = 2).

0 or FALSE:

print nothing.

1 or TRUE:

print only targets to build.

2:

in addition, print checks and cache info.

3:

in addition, print any potentially missing items.

4:

in addition, print imports. Full verbosity.

...

Value

An igraph object representing the dependency network of the workflow.

See Also

vis_drake_graph(), read_drake_config()

Examples

Run this code
# NOT RUN {
test_with_dir("Quarantine side effects.", {
load_mtcars_example() # Get the code with drake_example("mtcars").
make(my_plan) # Run the project, build the targets.
# Retrieve the igraph network from the cache.
g <- read_drake_graph()
class(g) # "igraph"
})
# }

Run the code above in your browser using DataLab