revwords: Load a set of stopwords

Description Usage Value Note Examples

View source: R/revtools_stopwords.R

Description

Generates a list of stopwords, consisting of all the terms given by tm::stopwords, plus some extra terms (mainly words that designate numbers).

Usage

1

Value

A vector of stopwords in English.

Note

This is primarily an internal function, but may be useful in other contexts.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
# import some data
file_location <- system.file(
  "extdata",
  "avian_ecology_bibliography.ris",
  package = "revtools")
x <- read_bibliography(file_location)

# construct a document-term matrix
x_dtm <- make_dtm(x$title,
  stop_words = revwords())
# Note that make_dtm calls revwords by default, so this is technically redundant

revtools documentation built on Jan. 8, 2020, 5:10 p.m.

Related to revwords in revtools...