Split a chr string by capture groups according to a regular expression provided.
chr string containing a regular expression with at least 1 capture '(', ')'
The string is returned as a matrix of start and stop position of substrings. These substrings are labelled by which capture group they belong to. Substrings outside a capture are labelled as 0.
Nested capturing groups do not work.
Num matrix indexing substrings of s. Each columns represents a substring. Row 1 is the label, Row 2 is the start, row 3 the stop letter of each substring. Substrings which are part of a capture are labelled with increasing numbers as they appear in s beginning with 1. Substrings which are not part of a capture are labelled with 0. If nothing was captured in chr s, NULL is returned.
1 2 3 4 5
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.