
ErrorData class
ErrorData.RdThis class represents an individual error found in the data. It includes the error description and the row numbers and column names where the error was found.
Public fields
descriptionA character string describing the error.
columnsA character vector of column names where the error was found.
rowsAn integer vector of row numbers where the error was found.
data_frameA dataframe of the samples that triggered the error.
Methods
Method new()
Initialize method for the ErrorData class.
Usage
ErrorData$new(
description = NULL,
columns = NULL,
rows = NULL,
data_frame = NULL
)Arguments
descriptionA character string describing the error. Default is NULL.
columnsA character vector of column names where the error was found. Default is NULL.
rowsAn integer vector of row numbers where the error was found. Default is NULL.
data_frameA data.frame with all of the invalid data. Can be used instead of providing rows and columns. Default is NULL.
Details
This method sets up a new ErrorData object. If a data.frame is provided, it will use its column names and the 'RowNumber' column for columns and rows, respectively. If not, the columns and rows arguments should be used. It will stop with an error if neither a data.frame is provided nor both columns and rows.