tok <- list(
tokens = list(
"1.1" = c("Hello", "world", "."),
"1.2" = c("This", "is", "an", "example", "."),
"2.1" = c("This", "is", "a", "party", "!")
)
)
dtm <- nlp_cast_tokens(tok)
Run the code above in your browser using DataLab