Check Whether an RDBESDataObject is in a Valid Format
Source: R/validateRDBESDataObject.R
validateRDBESDataObject.RdPerform basic checks on a object.
Usage
validateRDBESDataObject(
objectToCheck,
checkDataTypes = FALSE,
verbose = FALSE,
strict = TRUE
)
checkRDBESDataObject(
objectToCheck,
checkDataTypes = FALSE,
verbose = FALSE,
strict = TRUE
)Arguments
- objectToCheck
RDBESDataObject i.e. a list of data.tables
- checkDataTypes
(Optional) Set to TRUE if you want to check that the data types of the required columns are correct, or FALSE if you don't care. Default value is FALSE.
- verbose
(Optional) Set to TRUE if you want informative text printed out, or FALSE if you don't. The default is FALSE.
- strict
(Optional) Set to TRUE if you want an error if validation fails, set to FALSE if you want only a warning to be issued. The default is TRUE.
Details
Checks if 'objectToCheck' parameter is valid. Returns the parameter if it is
valid and otherwise stops on error.
It checks the RDBESDataObject if:
Is this an object of class RDBESDataObject
Tables don't have column names that aren't allowed
Tables have all the required column names
It does not check if the data is valid. The RDBES upload system performs an extensive set of checks on the uploaded data.
Examples
if (FALSE) { # \dontrun{
myH1RawObject <-
importRDBESDataCSV(rdbesExtractPath = "tests/testthat/h1_v_1_19")
validateRDBESDataObject(myH1RawObject)} # }