pipe_set_params_at_step: Set parameters at step

View source: R/aliases.R

pipe_set_params_at_stepR Documentation

Set parameters at step

Description

Set unbound function parameters defined at given pipeline step where 'unbound' means parameters that are not linked to other steps. If one or more parameters don't exist, an error is given.

Usage

pipe_set_params_at_step(pip, step, params)

Arguments

pip

Pipeline object

step

string the name of the step

params

list of parameters to be set

Value

returns the Pipeline object invisibly

Examples

p <- pipe_new("pipe", data = 1)
pipe_add(p, "add1", \(x = ~data, y = 2, z = 3) x + y)
pipe_set_params_at_step(p, step = "add1", params = list(y = 5, z = 6))
pipe_get_params(p)

try(
  pipe_set_params_at_step(p, step = "add1", params = list(foo = 3))
)

pipeflow documentation built on April 3, 2025, 10:50 p.m.