assert {StabPerf} | R Documentation |
If argument 'is.na' prints a warning and returns 'FALSE'
Description
If argument is.na
prints a warning and returns FALSE
Usage
Arguments
arg |
tested against is.na |
warning |
character. String to be printed in warning when arg is.na |
Value
success |
logical. FALSE when arg is.na , otherwise TRUE |
See Also
is.null
, is.na
Examples
result <- some.function()
# Check if we got a valid result, otherwise return NA to my own caller
if (!assert(result, "Failure Message")) return(NA)
[Package
StabPerf version 0.5
Index]