as_name: Coerce an object to a name or call.

View source: R/language.R

as_nameR Documentation

Coerce an object to a name or call.

Description

These are a S3 generics with built-in methods for names, calls, formuals, and strings. The distinction between a name and a call is particularly important when coercing from a string. Coercing to a call will parse the string, coercing to a name will create a (potentially) non-syntactic name.

Usage

as_name(x)

as_call(x)

Arguments

x

An object to coerce

Examples

as_name("x + y")
as_call("x + y")

as_call(~ f)
as_name(~ f())

hadley/lazyeval documentation built on June 19, 2022, 2:21 a.m.