Description Usage Arguments Details Value
View source: R/txx_identify_sections.R
This function identifies the tags within a character string, and then wraps
the identified text in XML tag syntax. Generally not used outside of the
txx_text_to_xml
function, but has its uses.
1 | txx_identify_sections(string, tags, ignore_case = TRUE)
|
string |
A character string of the document to be searched |
tags |
A vector of character strings - strings used to identify a section of text |
ignore_case |
Logic value of whether you want to ignore the case when identifying the sections |
Note that tag order is important - the first tags are identified first and modify the string. If there is another tag that would have identified a section within that string before the first tag, it would not identify it after.
Tags can be regular expressions - use with caution to avoid mis-identifying sections.
A character string with sections identified and wrapped in an XML tag.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.