runAutoReport | R Documentation |
Usually to be called by a scheduler, e.g. cron. If the provided day of year matches those of the config the report is run as otherwise specified in config. Functions called upon are expected to return a character string providing a path to a file that can be attached to an email or, in case of a bulletin, the email body itself. For bulletins, files cannot be attached. The email itself is prepared and sent to recipients defined in the config
runAutoReport(
dayNumber = as.POSIXlt(Sys.Date())$yday + 1,
type = c("subscription", "dispatchment"),
dryRun = FALSE
)
dayNumber |
Integer day of year where January 1st is 1. Defaults to
current day, i.e. |
type |
Character vector defining the type of reports to be processed.
May contain one or more of
|
dryRun |
Logical defining if emails are to be sent. If TRUE a message with reference to the payload file is given but no emails will actually be sent. Default is FALSE |
Emails with corresponding file attachment. If dryRun == TRUE just a message
# Example depend on environment variable R_RAP_CONFIG_PATH being set
runAutoReport()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.