Learn R Programming

tm.plugin.mail (version 0.3-2)

removeSignature: Remove E-Mail Signatures

Description

Remove signature lines from an e-mail message.

Usage

removeSignature(x, ...)
# S3 method for MailDocument
removeSignature(x, ...)
# S3 method for character
removeSignature(x, marks = character(), ...)

Arguments

x

A mail document or character vector.

marks

a character vector of signature identifications marks (in form of regular expression patterns). Note that the official signature start mark -- (dash dash blank) is always considered.

...

arguments to be passed to and from methods.

Author

Ingo Feinerer

See Also

removeCitation to remove e-mail citations, and removeMultipart to remove non-text parts from multipart e-mail messages.

Examples

Run this code
require("tm")
newsgroup <- system.file("mails", package = "tm.plugin.mail")
news <- VCorpus(DirSource(newsgroup),
                readerControl = list(reader = readMail))
news[[7]]
removeSignature(news[[7]], marks = "^[+]-*[+]$")

Run the code above in your browser using DataLab