我有一段文本:"At https://www.google.com/ you can google questions!"和我想通过使用str_remove_all删除带有包tidytext的URL。
发布于 2019-07-04 18:03:02
从基R和正则表达式中使用gsub。让你的生活更轻松。
text <- "At https://www.google.com/ you can google questions!"
gsub('http\\S+\\s*', '', text)
[1] "At you can google questions!"https://stackoverflow.com/questions/56892477
复制相似问题