Learn R Programming

statar (version 0.2)

vars: select variables in a data.frame

Description

select variables in a data.frame

Usage

vars(x, ...)

vars_not(x, ...)

vars_not_(x, .dots)

vars_(x, .dots)

Arguments

x
a data.frame
...
See the select documentation.
.dots
Needed to work around non-standard evaluation

Value

  • a character vector. All the syntax available in select_vars are allowed. Characters are understood as wildcards.

Examples

Run this code
df <- data.frame(id = 3, id2 = 4)
vars(df, id)
vars(df, w("id*"))

Run the code above in your browser using DataLab