is.language

0th

Percentile

Is an Object a Language Object?

is.language returns TRUE if x is a variable name, a call, or an expression.

Keywords
programming
Usage
is.language(x)
Arguments
x

object to be tested.

Note

A name is also known as ‘symbol’, from its type (typeof), see is.symbol.

This is a primitive function.

References

Becker, R. A., Chambers, J. M. and Wilks, A. R. (1988) The New S Language. Wadsworth & Brooks/Cole.

Aliases
  • is.language
  • language object
  • language objects
Examples
library(base) # NOT RUN { ll <- list(a = expression(x^2 - 2*x + 1), b = as.name("Jim"), c = as.expression(exp(1)), d = call("sin", pi)) sapply(ll, typeof) sapply(ll, mode) stopifnot(sapply(ll, is.language)) # }
Documentation reproduced from package base, version 3.4.3, License: Part of R 3.4.3

Community examples

Looks like there are no examples yet.