Learn R Programming

DCC (version 1.2.1)

dcc_audit_log: Accessors for dcc_result objects

Description

Access the machine-readable audit log and the cleaned dataset produced by the Execute stage. The audit log is the backbone of DCC's auditable-reporting guarantee: every row records one change traceable to one finding.

Usage

dcc_audit_log(x)

dcc_cleaned(x)

Value

dcc_audit_log returns the cell-level audit log (data.table with columns record_id, variable, old_value, new_value, action, check_id, method, timestamp, dcc_version, ruleset_hash, keyfile_hash). dcc_cleaned returns the new dcc_data version.

Arguments

x

A dcc_result from dcc_execute.

Examples

Run this code
df <- data.frame(sid = "S1", q1 = 9)
f <- dcc_findings("S1", variable = "q1", check_id = "C",
                  evidence = "legacy code")
res <- dcc_execute(df, f, actions = list(C = "set_na"), id_var = "sid")
dcc_audit_log(res)
dcc_cleaned(res)

Run the code above in your browser using DataLab