Learn R Programming

REDCapTidieR (version 1.2.3)

check_redcap_populated: Check that a supplied REDCap database is populated

Description

Check for potential outputs where metadata is present, but nrow and ncol equal 0. This causes multi_choice_to_labels to fail, but a helpful error message should be provided.

Usage

check_redcap_populated(db_data, call = caller_env())

Value

A helpful error message alerting the user to check their API privileges.

Arguments

db_data

The REDCap database output generated by REDCapR::redcap_read_oneshot()$data

call

the calling environment to use in the error message