grepdf: Grep for column names from a 'data.frame'

Description Usage Arguments Value See Also Examples

View source: R/grepdf.R

Description

Grep for column names from a data.frame

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
grepdf(
  pattern,
  x,
  ...,
  ignore.case = FALSE,
  perl = FALSE,
  value = FALSE,
  fixed = FALSE,
  useBytes = FALSE,
  invert = FALSE
)

Arguments

pattern

passed to grep

x

data.frame to work with

...

force later arguments to be passed by name

ignore.case

passed to grep

perl

passed to grep

value

passed to grep

fixed

passed to grep

useBytes

passed to grep

invert

passed to grep

Value

column names of x matching grep condition.

See Also

grep, grepv

Examples

1
2
3
4
5
6
7
d <- data.frame(xa=1, yb=2)

# starts with
grepdf('^x', d)

# ends with
grepdf('b$', d)

WinVector/wrapr documentation built on Nov. 21, 2020, 8:31 p.m.