reglook.default: Search an object by regular expression.

View source: R/general_oop.R

reglookR Documentation

Search an object by regular expression.

Description

Select elements of a vector or data frame records which match the given regular expression.

Usage

reglook(object, ...)

## Default S3 method:
reglook(object, regex, ...)

## S3 method for class 'data.frame'
reglook(object, regex, keys = NULL, multiple = c("OR", "AND"), ...)

## S3 method for class 'mdbib'
reglook(object, regex, keys = NULL, multiple = c("OR", "AND"), ...)

Arguments

object

an object to be searched.

...

extra arguments, currently none.

regex

a regular expression.

keys

a vector of data frame variable names to be included in the search. Defaults to NULL, which means that all variables will be looked up.

multiple

ignored when a single search key is provided. It describes how searching results from multiple data frame columns will be handled. 'OR' (default) specifies that the multiply column search results will be merged by logical sum, for 'AND' they will be merged by logical intersection.

Details

'reglook()' is a S3 generic function with methods defined for the 'data_frame' and 'default' class.

Value

an object of the same class as the input one.

a mdbib object.


PiotrTymoszuk/figur documentation built on July 16, 2024, 1:15 a.m.