I am new to R and been trying to tokenize a data.frame using unnest_tokens. My data.frame was obtained from a csv file and has the following column :
ID, TITLE, DESCRIPTION, OUTCOMES, DATE .
I WISH TO TOKENIZE THE TITLE, SO I MADE ANOTHER DATAFRAME :
only_t<-dplyr::select(mydata,title)
up_dat<-data.frame(1:2156, document= only_t)
Followed by I did :
up_dat %>%
tidytext::unnest_tokens(word, document)
When I did this , I get an error stating :
Error in check_input(x) : Input must be a character vector of any length or a list of character vectors, each of which has a length of 1.
Would appreciate any help in this. I been stuck here forever .