extract_vars: Extract All Symbols from a List of Expressions

View source: R/dev_utilities.R

extract_varsR Documentation

Extract All Symbols from a List of Expressions

Description

Extract All Symbols from a List of Expressions

Usage

extract_vars(x, side = "lhs")

Arguments

x

An R object

Default value

none

side

One of "lhs" (the default) or "rhs" for formulas

Default value

"lhs"

Value

A list of expressions

See Also

Developer Utility Functions: %notin%(), %or%(), arg_name(), contains_vars(), convert_dtm_to_dtc(), filter_if(), friendly_type_of(), valid_time_units(), vars2chr()

Examples

library(rlang)
extract_vars(exprs(PARAMCD, (BASE - AVAL) / BASE + 100))
extract_vars(AVAL ~ ARMCD + AGEGR1)
extract_vars(AVAL ~ ARMCD + AGEGR1, side = "rhs")

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