newsgroup <- system.file("texts", "newsgroup", package = "tm")
news <- Corpus(DirSource(newsgroup), readerControl = list(reader = readNewsgroup, language = "en_US", load = TRUE))
asPlain(news[[4]])
removeSignature(asPlain(news[[4]]))
asPlain(news[[5]])
removeSignature(asPlain(news[[5]]), marks = "^[+]-*[+]$")
Run the code above in your browser using DataLab