Replace substrings in documents
replaces all occurrences of the substring or pattern newDocuments
= replace(documents
,old
,new
)old
in
documents
with new
.
Tip
Use the replace
function to replace substrings of the
words in documents by specifying substrings or patterns. To replace entire
words and n-grams in documents, use the replaceWords
and replaceNgrams
functions respectively.
bagOfWords
| decodeHTMLEntities
| normalizeWords
| regexprep
| replaceNgrams
| replaceWords
| tokenizedDocument