| pip_remove | R Documentation |
If other steps depend on the step to be removed, an error is
given and the removal is blocked, unless recursive was set to
TRUE. In recursive mode, the selected step and all downstream
dependent steps are removed together.
pip_remove(x, step, recursive = FALSE)
x |
A pipeflow pip |
step |
|
recursive |
|
The updated pipeline, invisibly.
p <- pip_new() |>
pip_add("load", \(x = 1) x) |>
pip_add("transform", \(x = ~load) x * 2) |>
pip_add("model", \(x = ~transform) x + 10)
# Removing a leaf step (nothing depends on it) works directly
pip_remove(p, "model")
p # "load", "transform"
# Trying to remove a step that others depend on raises an error:
# pip_remove(p, "load") # Error!
# recursive = TRUE removes the step and all its downstream dependents
pip_remove(p, "load", recursive = TRUE)
p # pipeline is now empty
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.