assemble_call: Assembles a formatted function call from a function and a...

View source: R/enchunk.R

assemble_callR Documentation

Assembles a formatted function call from a function and a list of parameters

Description

Assembles a formatted function call from a function and a list of parameters

Usage

assemble_call(fun_name, params, non_char = NULL)

Arguments

fun_name

Name of the function to be called (must be a character or coercible to a character).

params

Named list or vector containing the parameters for the fun call.

non_char

Names of the parameters whose values should not be interpreted as character values

Value

A character string with the formatted function call.

Examples

chronicle::assemble_call(fun_name = 'base::sapply',
                         params = list(X = 'iris',
                                       FUN= 'class'))
chronicle::assemble_call(fun_name = 'base::sapply',
                         params = list(X = 'iris',
                                       FUN= 'class'),
                         non_char = c('X', 'FUN'))

pheymanss/chronicle documentation built on Jan. 19, 2024, 6 a.m.