Skip to content

dfm() Rd still includes ngrams argument #1990

Description

@kbenoit

We need to remove the ngrams argument from the examples for dfm(). They're not executing and producing warnings instead.

featnames(dfm(corp, ngrams = 2, select = stopwords("english"), remove_punct = TRUE))
#> Warning: ngrams argument is not used.
#> [1] "the"  "over" "with" "from" "a"    "in"   "his" 

The error is from

quanteda/R/dfm.R

Lines 84 to 85 in e16b4ba

#' featnames(dfm(corp, ngrams = 2, select = stopwords("english"), remove_punct = TRUE))
#' featnames(dfm(corp, ngrams = 1:2, select = stopwords("english"), remove_punct = TRUE))

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions