Learn R Programming

cleanNLP (version 2.3.0)

cnlp_extract_documents: Extract documents from an annotation object

Description

Takes an annotation object and returns an annotation object containing only a subset of the documents.

Usage

cnlp_extract_documents(anno, ids)

Arguments

anno

the object to extract from

ids

a vector of document ids from which to extract

Value

a new annotation object

Examples

Run this code
# NOT RUN {
annotation <- extract_documents(anno, ids = c(0, 1, 2, 3))
# }
# NOT RUN {
# }

Run the code above in your browser using DataLab