The colors targets::tar_visnetwork() uses for target status, as a
hard-coded copy - they belong to targets, not ggtargets, and are
checked against the installed targets version in the package's own
tests, so a drift is caught rather than silently shipped. Fits the
palette argument of tar_ggplot()/ggplot_dag()/dag_layers()
directly, e.g.
tar_ggplot(node_color = "status", palette = targets_status_colors()).
Examples
targets_status_colors()
#> completed uptodate outdated dispatched canceled errored queued
#> "#E1BD6D" "#354823" "#78B7C5" "#DC863B" "#FAD510" "#C93312" "#D2D2D0"
#> skipped none
#> "#7500D1" "#94a4ac"
dag <- as_dag(
data.frame(from = c("a", "a", "b"), to = c("b", "c", "c")),
nodes = data.frame(name = c("a", "b", "c"), status = c("uptodate", "outdated", "errored"))
)
ggplot_dag(dag, node_color = "status", palette = targets_status_colors())