tests/testthat/test-vectorize.R

test_that("vectorisation works", {

  enron <- readRDS(testthat::test_path("data", "enron.rds"))

  testthat::expect_snapshot(vectorize(enron, tokens = "character", remove_punct = F, remove_symbols = T,
                                      remove_numbers = T, lowercase = T, n = 5, weighting = "rel", trim = T,
                                      threshold = 1500))

})

Try the idiolect package in your browser

Any scripts or data that you put into this service are public.

idiolect documentation built on Sept. 11, 2024, 5:34 p.m.