Description Usage Arguments Value Examples
The convenience function usually provide some defaults like description that can be overwritten by the user through the ... argument of the convenience function. This function manages to set those values that were NOT overwritten by the user through the ... argument and then call add_sanity_check.
1 2 3 4 5 6 7 8 9 10 | h_add_sanity_check(
ellipsis,
fail_vec,
.generated_desc,
data,
data_name = "",
param_name = "",
call = h_deparsed_sys_call(which = -2),
.fail_vec_str = checkmate::vname(x = fail_vec)
)
|
ellipsis |
usually list(...) of the function that calls this function. It contains the parameters defined by the user for add_sanity_check. |
fail_vec |
logical vector where |
.generated_desc |
will be passed to .add_sanity_check if ellipsis does not contain a element with name 'description' |
data |
will be passed to .add_sanity_check if ellipsis does not contain a element with name 'data' |
data_name |
will be passed to .add_sanity_check if ellipsis does not contain a element with name 'data_name' |
param_name |
will be passed to .add_sanity_check if ellipsis does not contain a element with name 'param_name' |
call |
will be passed to .add_sanity_check if ellipsis does not contain a element with name 'call' |
.fail_vec_str |
usually not used by the user. Captures what
was passed to |
see return value of add_sanity_check
1 2 3 4 | d <- data.frame(type = letters[1:4], nmb = 1:4)
# h_add_sanity_check is used on sc_col_elements()
sc_col_elements(object = d, col = "type", feasible_elements = letters[2:4])
get_sanity_checks()
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.