readPlain

0th

Percentile

Read In a Text Document

Read in a text document without knowledge about its internal structure and possible available metadata.

Usage
readPlain(elem, language, id)
Arguments
elem

a named list with the component content which must hold the document to be read in.

language

a string giving the language.

id

a character giving a unique identifier for the created text document.

Value

A PlainTextDocument representing elem$content. The argument id is used as fallback if elem$uri is null.

See Also

Reader for basic information on the reader infrastructure employed by package tm.

Aliases
  • readPlain
Examples
# NOT RUN {
docs <- c("This is a text.", "This another one.")
vs <- VectorSource(docs)
elem <- getElem(stepNext(vs))
(result <- readPlain(elem, "en", "id1"))
meta(result)
# }
Documentation reproduced from package tm, version 0.7-8, License: GPL-3

Community examples

Looks like there are no examples yet.