qc_check_unsigned | R Documentation |
This function performs a quality control check to ensure that a given field value is an unsigned number (i.e., a non-negative number). Optionally, it can also check if the field value matches a specified data type before performing the unsigned check.
qc_check_unsigned(field_value, expected_type = NULL)
field_value |
The value to be checked. The function verifies if this value is non-negative. It can be of any type but is typically expected to be a numeric value. |
expected_type |
An optional parameter specifying the expected data type of
|
Returns the field_value
if it passes the checks: it is of the expected
type (if expected_type
is not NULL) and is non-negative. If any of the
checks fail, the function logs an error message and aborts execution.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.