50% off: Unlimited data and AI learning.
State of Data and AI Literacy Report 2025

pipeflow (version 0.2.2)

pipe_pop_step: Pop steps from the pipeline

Description

Use this function to drop steps from the end of the pipeline.

Usage

pipe_pop_step(pip)

pipe_pop_steps_after(pip, step)

pipe_pop_steps_from(pip, step)

Value

string the name of the step that was removed

Arguments

pip

Pipeline object

step

string name of step

Methods

  • pipe_pop_step: drop last step from the pipeline

  • pipe_pop_steps_after: drop all steps after given steps

  • pipe_pop_steps_from: drop all steps from and including given steps

Examples

Run this code
# pipe_pop_step
p <- pipe_new("pipe", data = 1:2)
pipe_add(p, "f1", \(x = 1) x)
pipe_add(p, "f2", \(y = 1) y)
p
pipe_pop_step(p)
p

# pipe_pop_steps_after
pipe_add(p, "f2", \(y = 1) y)
pipe_add(p, "f3", \(z = 1) z)
p
pipe_pop_steps_after(p, "f1")
p

# pipe_pop_steps_from
pipe_add(p, "f2", \(y = 1) y)
pipe_add(p, "f3", \(z = 1) z)
p
pipe_pop_steps_from(p, "f1")
p

Run the code above in your browser using DataLab