Check the integrity of RData / qs2 / rds / feather files
Source: R/general_check_data.R
Check_data.RdThese functions validate a given file by checking its extension and
attempting to load its contents. A file is considered valid if it loads
successfully and contains a non-null object, returning TRUE. Otherwise, it
returns FALSE.
Usage
check_data(file, warning = TRUE, n_threads = 5)
check_RData(file, warning = TRUE)
check_qs(file, warning = TRUE, n_threads = 5)
check_rds(file, warning = TRUE)
check_feather(file, warning = TRUE)Details
The check_data() function determines the file type based on its
extension. If the extension is unrecognized, it returns FALSE. Supported
file types:
RData: Checked with
check_RData(), read using load_asqs2: Checked with
check_qs(), read using qs2::qs_readrds: Checked with
check_rds(), read using readRDSfeather: Checked with
check_feather(), read using arrow::read_feather