View source: R/preprocess_source.R
preprocess_source | R Documentation |
Efficiently preprocess data
preprocess_source(
input,
output = NULL,
clean = TRUE,
cleaningArgs = NULL,
wordwrap = TRUE,
wrappingArgs = NULL,
prependUIDs = TRUE,
UIDArgs = NULL,
preventOverwriting = rock::opts$get("preventOverwriting"),
encoding = rock::opts$get("encoding"),
rlWarn = rock::opts$get("rlWarn"),
silent = rock::opts$get("silent")
)
input |
The source |
output |
For |
clean |
Whether to clean |
cleaningArgs |
Arguments to use for cleaning |
wordwrap |
Whether to wordwrap |
wrappingArgs |
Arguments to use for word wrapping |
prependUIDs |
Whether to prepend UIDs |
UIDArgs |
Arguments to use for prepending UIDs |
preventOverwriting |
Whether to prevent overwriting of output files. |
encoding |
The encoding of the source(s). |
rlWarn |
Whether to let |
silent |
Whether to suppress the warning about not editing the cleaned source. |
The preprocessed source as character vector.
exampleText <-
paste0(
"Lorem ipsum dolor sit amet, consectetur ",
"adipiscing elit. Nunc non commodo ex, ac ",
"varius mi. Praesent feugiat nunc eget urna ",
"euismod lobortis. Sed hendrerit suscipit ",
"nisl, ac tempus magna porta et. ",
"Quisque libero massa, tempus vel tristique ",
"lacinia, tristique in nulla. Nam cursus enim ",
"dui, non ornare est tempor eu. Vivamus et massa ",
"consectetur, tristique magna eget, viverra elit."
);
### Show example text
cat(exampleText);
### Show preprocessed example text
rock::preprocess_source(
exampleText
);
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.