match_args {tidyAML}R Documentation

Match function arguments

Description

Match a functions arguments.

Usage

match_args(f, args)

Arguments

f

The parsnip function such as "linear_reg" as a string and without the parentheses.

args

The arguments you want to supply to f

Details

Match a functions arguments, the bad ones passed will be rejected but the remaining passing ones will be returned.

Value

A list of matched arguments.

Author(s)

Steven P. Sanderson II, MPH

See Also

Other Utility: core_packages(), create_splits(), create_workflow_set(), fast_classification_parsnip_spec_tbl(), fast_regression_parsnip_spec_tbl(), full_internal_make_wflw(), install_deps(), load_deps()

Examples


match_args(
  f = "linear_reg",
  args = list(
    mode = "regression",
    engine = "lm",
    trees = 1,
    mtry = 1
   )
 )


[Package tidyAML version 0.0.5 Index]