call_with_args: Call with filtered argument list

View source: R/utils.R

call_with_argsR Documentation

Call with filtered argument list

Description

Call a function with a list of arguments, eliminating any that aren't matched in the function prototype

Usage

call_with_args(fun, args, other_valid = list(), keep_all = FALSE,
  silent = FALSE, ignore = c())

Arguments

fun

A function whose signature will be used to reduce the

args

A list of function arguments to use.

other_valid

A list of function arguments names that are valid, but not formals of fun.

keep_all

A logical don't drop arguments, even if they aren't matched in either the function prototype or other_valid.

silent

A logical indicating whether to pass messages when arguments not found in formals are passed to fun.

ignore

A character vector indicating which arguments should be dropped


jeremyrcoyle/sl3 documentation built on April 30, 2024, 10:16 p.m.