I take part in an Kaggle- competition, just to learn tidymodels and textmodelling.
Modified some scripts from
Supervised machine learning for text analysis in R
When I try to build a recipe it works perfect on my local computer:
{r receipe}
max_words <- 15500
max_length <- 190
lit_rec <- recipe(~ excerpt, data = lit_train) %>%
step_tokenize(excerpt) %>%
step_tokenfilter(excerpt, max_tokens = max_words) %>%
step_sequence_onehot(excerpt, sequence_length = max_length)
lit_prep <- prep(lit_rec)
Running the kaggle notebook it stops with an error:
Error: can't subset columns that don't exist
x Location 190 doesn't exist
i There are only one column