rmdwcl: Word-, character and non-whitespace characters count for a...

Description Usage Arguments Value Examples

Description

Counts words, characters and non-whitespace characters in a string. Is used in rmdcount, see details there.

Usage

1
rmdwcl(rmd, space = "[[:space:]]", word = "[[:space:]]+")

Arguments

rmd

character: R Markdown document as string

space

character: pattern to split a text at spaces (default: '[[:space:]]')

word

character: pattern to split a text at word boundaries (default: '[[:space:]]+')

Value

a list

Examples

1
2
3
file  <- system.file('rmarkdown/rstudio_pdf.Rmd', package="rmdwc")
fcont <- readChar(file, file.info(file)$size)
rmdwcl(fcont)

rmdwc documentation built on Aug. 27, 2020, 5:08 p.m.