qprep | R Documentation |
Wrapper for bracketX
, replace_number
,
replace_symbol
, replace_abbreviation
and scrubber
to quickly prepare text for analysis. Care
should be taken with this function to ensure data is properly formatted and
complete.
qprep(
text.var,
rm.dash = TRUE,
bracket = "all",
missing = NULL,
names = FALSE,
abbreviation = qdapDictionaries::abbreviations,
replace = NULL,
ignore.case = TRUE,
num.paste = TRUE,
...
)
text.var |
The text variable. |
rm.dash |
logical. If |
bracket |
The type of bracket (and encased text) to remove. This is one
of the strings |
missing |
Value to assign to empty cells. |
names |
logical. If |
abbreviation |
A two column key of abbreviations (column 1) and long
form replacements (column 2) or a vector of abbreviations. Default is to use
qdap's abbreviations data set. Also takes the argument |
replace |
A vector of long form replacements if a data frame is not supplied to the abbreviation argument. |
ignore.case |
logical. If |
num.paste |
logical. If |
... |
Other arguments passed to |
Care should be taken with this function to ensure data is properly formatted and complete.
bracketX
,
replace_abbreviation
,
replace_number
,
replace_symbol
## Not run:
x <- "I like 60 (laughter) #d-bot and $6 @ the store w/o 8p.m."
qprep(x)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.