assert | R Documentation |
This function is a wrapper of stopifnot()
, tryCatch()
and
cli::cli_abort()
and asserts the truthfulness of the passed expression(s).
assert(..., error_message = NULL)
... |
expressions >= 1. If named the names are used as error messages, otherwise R's internal error-messages are thrown |
error_message |
character. An error message, supports formatting with the cli package. |
NULL if all statements in ... are TRUE
stopifnot()
, cli::cli_abort()
, tryCatch()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.