Perform CC-HIC Data Quality Evaluation

perform_evaluation(
  connection = NULL,
  output_folder = NULL,
  translate_site = NULL,
  test_comparisons = NULL,
  verbose = TRUE,
  .debug = FALSE
)

Arguments

output_folder

character vector length 1 for the file path name for plots to be stored. If left as NULL (the default) then no plots will be written out.

translate_site

a lookup table to translate site names on export in a consistent way. The table requires two columns: site and translation. The site column should be a character vector with names of the existing sites as they are stored in the database (e.g. c("GSTT", "RGT") etc). The translation column should be a character vector with new names to obfuscate the real names (e.g. c("Site A", "Site B") etc). This is a 1:1 mapping so doesn't confer any real privacy advantage, but is useful as a means to casually obscure data origins.

test_comparisons

a lookup table with the following columns:

  • event_a (chr): code_name for event to be used on the left hand side of the evaluation in evaluate_comparison().

  • event_b (chr): code_name for event to be used on the right hand side of the evaluation in evaluate_comparison().

  • operation (chr): string to identify the comparison to be made. See the documentation in the evaluate_comparison() function.

The default behaviour is to evaluate the comparisons found in the .comparisons_lookup object. This object also serves to illustrate the correct format to use.

verbose

logical flag to print progress to the console

.debug

logical flag to use internal test data

database

a database object returned by DBI::dbConnect()

Value

TRUE if completes without errors

Details

Performs a full data quality evaluation for CC-HIC. This wraps all other functions in inspectEHR as necessary to evaluate the whole CC-HIC database in one easy sweep. This can take some time so please grab a coffee!