get_construct: Extract Script from 'reverse_construct' to 'construct' a...

Description Usage Arguments Value Examples

View source: R/as.regexr.R

Description

Pulls the reverse_construct attribute from a reverse_construct. This script can be assigned to an object and run in the console to create a comments, named regexr object.

Usage

1

Arguments

x

A reverse_construct object.

file

A connection, or a character string naming the file to print to. If "" (the default), cat prints to the console unless redirected by sink. Windows users may use file = "clipboard" to copy the content to the clipboard.

...

Other arguments passed to print.reverse_construct.

Value

Returns an auto-commented script used to construct a regexr object.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
## Not run: 
library("qdapRegex")
(myregex <- grab("@rm_time2"))
out <- as.regexr(myregex)

out
summary(out)
comments(out)
subs(out)
test(out)
get_construct(out)

## On Windows copy to clipboard
get_construct(out, file="clipboard")

## End(Not run)

regexr documentation built on May 29, 2017, 5:57 p.m.