View source: R/write_reports_local.R
The 'write_reports' function will do a data pull using RODBC. In case you do not have a connection to BioSense_Platform through RODBC, you can use this function to run the reports on data that are loaded to your current R session. That way, you can load in files yourself if you need to write reports for data have already been pulled or been pulled down using other means than the RODBC package.
1 | write_reports_local(data, fnames, directory = "", nexamples = 0)
|
data |
A data frame of raw data from the BioSense Platform. |
fnames |
A data frame that includes two variables: C_Biosense_Facility_ID and Facility_Name. Make sure there is NO repeat C_Biosense_Facility_ID numbers. |
directory |
The directory where you would like to write the reports to (i.e., "~/Documents/MyReports"), as a string. |
nexamples |
An integer number of examples you would like for each type of invalid or null field in the examples workbooks for each facility. This defaults to 0, which will not generate these example workbooks. |
offset |
The number of hours you wish to offset Arrived_Date_Time (which is in UTC). The offset value is how far off your local time zone is from UTC. For example, the Central Time Zone would set this to 5 or 6, depending on if it is daylight savings or not. This value should be an integer. This is used for timeliness reports using the 'va_lag' function. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.