Dear RStudio Community,
I am very new to RStudio and to tidyverse, so please pardon my ignorance. I am trying to prepare a set of plays for computational analysis (including tf-idf) but am running into difficulties from the get-go. I tried to follow Text Mining with R, using a text file I have prepared, but when I type the following:
baillie.v <- scan("14 plays from Collected stripped intervening metadata.txt", what="character", sep= "\n")
text_df <- tibble(line = 1:4, text = baillie.v)
I receive this error:
Error: Tibble columns must have compatible sizes.
- Size 4: Existing data.
- Size 43934: Column
text.
i Only values of size one are recycled.
Having looked through similar topics, I see that "tibble does not automatically recycle vectors to match length, hence the error." But I do not know how to apply the fix suggested there to my variable.
I would appreciate any help.
Sincerely,
Steve Newman