The return value is a tidy data frame where each row
corresponds to an element of the input character vector text
. The
values from text
appear for reference in the .text
character
column. All other columns are list columns containing the match data. The
.match
column contains the match information for full regular
expression matches while other columns correspond to capture groups if there
are any, and PCRE matches are enabled with perl = TRUE
(this is on by
default). If capture groups are named the corresponding columns will bear
those names.
Each match data column list contains match records, one for each element in
text
. A match record is a named list, with entries match
,
start
and end
that are respectively the matching (sub) string,
the start, and the end positions (using one based indexing).