file.scan: file-scan.r Function to find a pattern in files with...

Description Usage Arguments Examples

View source: R/file-scan.r

Description

file-scan.r Function to find a pattern in files with user-defined extension (.r by default) Returns file name and approximate row matches if positive.

Usage

1
2
file.scan(pattern, dir = getwd(), fpattern = NA,
  ftype = "\\.r$|\\.R$", show.line = FALSE)

Arguments

pattern

pattern to look for (can be regexp)

dir

directory to search files in, defaults to working directory

fpattern

file extension pattern (optional)

ftype

defaults to R files, accepts regular expressions

show.line

if TRUE, prints out the line where the pattern is found

Examples

1

lauratboyer/ltb.utils documentation built on May 20, 2019, 7:57 p.m.