Learn R Programming

lint (version 0.3)

check_pattern: Check a pattern against lines

Description

This is part of lint which checks lines of text for stylistic problems. The pattern provided should be a Perl compatible regular expression.

Usage

check_pattern(pattern, lines, ...)

Arguments

lines
character vector of lines of text to check, output from readLines.
pattern
Perl compatible regular expression.
...
discarded.

Value

returns an integer vector of the problem lines if problems were found. otherwise returns TRUE if the lines pass the check. isTRUE could be useful for checking the return value.find compatible format.

See Also

Other lint: lint