In that case, something like:
library(tidyverse)
library(tidytext)
df = tibble(sentences = c("this is a really long sentence", "R is good for text analysis"))
df |>
unnest_tokens(word, sentences) |>
anti_join(get_stopwords())
# A tibble: 7 x 1
word
<chr>
1 really
2 long
3 sentence
4 r
5 good
6 text
7 analysis
Note that it is often useful to provide a reproducible example when asking for help, otherwise we can only guess at what your data looks like.
FAQ: What's a reproducible example (reprex
) and how do I create one?