I am trying to run a basic sentence annotation function and I keep running into the same error.
The code I tried to use is:
s <- as.String(cleandata) #cleandata is my data.It is a character class.
sent_ann <- Maxent_Sent_Token_Annotator()
a2 <- annotate(s,sent_ann)
The above code keeps generating the error:
Error in as.data.frame.default(x[[i]], optional = TRUE) :
cannot coerce class "c("Simple_Sent_Token_Annotator", "Annotator")" to a data.frame
What do I do ?