explain(pattern, open = FALSE, print = TRUE,
dictionary = getOption("regex.library"))
Arguments
pattern
A character string containing a regular expression or a
character string starting with "@" that is a regular
expression from a qdapRegex dictionary.
open
logical. If TRUE the default browser will attempt to
open http://www.regexper.com page. Setting open = 2 will
utilize an unstable visualization via https://www.debuggex.com. This
approach utilizes a non-api scrape that is subject to change and not
guaranteed to be stable. The regex is set to Python flavor which handles
lookbehinds that the Java based http://www.regexper.com does not. This
functionality was developed by
Matthew Flickinger (see
http://stackoverflow.com/a/27574103/1000343 for details). Note that
the user must have httr installed or will be prompted if the package
cannot be required.
print
logical. Should explain print output to the console?
dictionary
A dictionary of canned regular expressions to search within.
# NOT RUN {explain("\\s*foo[A-Z]\\d{2,3}")
explain("@rm_time")
# }# NOT RUN {explain("\\s*foo[A-Z]\\d{2,3}", open = TRUE)
explain("@rm_time", open = TRUE)
# }