add_suffix_to_vars: Add a Suffix to Variables in a List of Expressions

View source: R/quo.R

add_suffix_to_varsR Documentation

Add a Suffix to Variables in a List of Expressions

Description

Add a suffix to variables in a list of expressions

Usage

add_suffix_to_vars(order, vars, suffix)

Arguments

order

List of expressions

Permitted values

list of variables or ⁠desc(<variable>)⁠ function calls created by exprs(), e.g., exprs(ADT, desc(AVAL))

Default value

none

vars

Variables to change

Permitted values

list of variables created by exprs(), e.g., exprs(USUBJID, VISIT)

Default value

none

suffix

Suffix

Permitted values

a character scalar, i.e., a character vector of length one

Default value

none

Value

The list of expression where for each element the suffix (suffix) is added to every symbol specified for vars

See Also

Helpers for working with Quosures: expr_c(), replace_symbol_in_expr(), replace_values_by_names()

Examples

library(dplyr, warn.conflicts = FALSE)
library(rlang)

add_suffix_to_vars(exprs(ADT, desc(AVAL), AVALC), vars = exprs(AVAL), suffix = ".join")

admiraldev documentation built on June 26, 2025, 1:09 a.m.