Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

indexOf.GenericDataFileSet

Finds indices of a subset of files


Description

Finds indices of a subset of files whose names match a given set of names or name patterns.

Usage

## S3 method for class 'GenericDataFileSet'
indexOf(this, patterns=NULL, by=c("exact", "regexp", "fixed"), ...,
  onMissing=c("NA", "error"))

Arguments

patterns

A character vector of length K of names and/or regular expressions to be matched.

by

A character vector specifying how and in what order the name matching is done.

...

Not used.

Details

If an element of patterns contains a comma, then that element is matched against the *getFullNames(), otherwise it is matched against *getNames(). First each pattern is matched by regular expression rules, and if there is not match, then by fixed strings.

Value

Returns an integer vector of length K with elements in [1,*length()] or (integer) NA (for non-matched names).

Author(s)

Henrik Bengtsson

See Also

*getNames() For more information see GenericDataFileSet.


R.filesets

Easy Handling of and Access to Files Organized in Structured Directories

v2.14.0
LGPL (>= 2.1)
Authors
Henrik Bengtsson [aut, cre, cph]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.