output$Table <-
renderTable(
myData()%>%mutate(searchmatch<-str_extract(DocumentText,"([^\\s]+\\s){50}to treat(\\s[^\\s]+){50}"))
)
This final section of my code searches 'DocumentText' for a character string and adds it into a new column. I would like to drop the 'DocumentText' column after the new column is added as it is very large, I have tried using select(myData,-DocumentText) but this didn't work. I also tried using myData([-2],) bu this also failed; Any suggestions would be great
myData? Is it a function? If it is a dataframe, thenmyData[-2]ormyData[, -2]