Title: | Check the Basic Validity of a (Function) Argument |
---|---|
Description: | Utility functions that allow checking the basic validity of a function argument or any other value, including generating an error and assigning a default in a single line of code. The main purpose of the package is to provide simple and easily readable argument checking to improve code robustness. |
Authors: | Ivo Van Walle [aut, cre] |
Maintainer: | Ivo Van Walle <[email protected]> |
License: | GPL (>= 2) |
Version: | 0.2.0 |
Built: | 2024-11-04 06:19:50 UTC |
Source: | https://github.com/ivwalle/checkarg |
This function is the main function that all isXxx functions are wrappers around, each with specific parameter settings. It can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
checkarg(argument, content, default = NULL, stopIfNot = FALSE, nullAllowed = FALSE, n = 1, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, nonIntegerAllowed = TRUE, negativeAllowed = TRUE, zeroAllowed = TRUE, positiveAllowed = TRUE, emptyStringAllowed = TRUE, message = "Argument \\1has invalid value", argumentName = "")
checkarg(argument, content, default = NULL, stopIfNot = FALSE, nullAllowed = FALSE, n = 1, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, nonIntegerAllowed = TRUE, negativeAllowed = TRUE, zeroAllowed = TRUE, positiveAllowed = TRUE, emptyStringAllowed = TRUE, message = "Argument \\1has invalid value", argumentName = "")
argument |
Argument to check. |
content |
Required content of argument, case-insensitive. Either "BOOLEAN" (short: "B") for an argument of primitive type logical, "NUMBER" (short: "N") for an argument of primitive type numeric, or "STRING" (short: "S") for an argument of primitive type character. |
default |
If not NULL and the argument is NULL, the default value is returned instead of the result of the content checks (TRUE or FALSE). Parameter stopIfNot must be set to TRUE in this case. The content of the default value is not checked. |
stopIfNot |
If TRUE and the argument checks fail, an exception is be thrown. Must be set to TRUE if parameter default is not NULL. |
nullAllowed |
If TRUE, argument may be NULL. |
n |
Number of elements the argument must have. Default: n = 1, i.e. a scalar value is expected. If NA, any length is allowed. If the argument has zero elements and either n = 0 or n = NA, only the primitive type is checked and no other checks on content are applied. |
naAllowed |
If TRUE, NA value(s) are allowed. If FALSE, NaN value(s), which also test true for is.na, are ignored and can be further constrained by nanAllowed. |
nanAllowed |
If TRUE, NaN value(s) are allowed. |
infAllowed |
If TRUE, Inf value(s) are allowed. |
nonIntegerAllowed |
If TRUE, non-integer value(s) are allowed. If FALSE, NA, NaN and Inf value(s), which are not integers, are ignored and can instead be constrained further by respectively naAllowed, nanAllowed and infAllowed. |
negativeAllowed |
If TRUE, negative value(s) are allowed. |
zeroAllowed |
If TRUE, zero value(s) are allowed. |
positiveAllowed |
If TRUE, positive value(s) are allowed. |
emptyStringAllowed |
If TRUE, empty string value(s) are allowed. |
message |
The message provided when an exception is thrown. The first instance of \1 is replaced with '\'argumentName\' ', if the latter is not empty. If NULL, the same default message is used. |
argumentName |
The name of the variable to be used in the exception message. If NULL, the same default argumentName is used. |
If no default is provided, i.e. if the default parameter is not null): TRUE is returned if the argument passes the checks and otherwise FALSE. If a default is provided, the default is returned in case the argument is null and otherwise the argument is returned.
checkarg(TRUE, "BOOLEAN") # returns TRUE (argument is valid) checkarg(FALSE, "BOOLEAN") # returns TRUE (argument is valid) checkarg(1, "BOOLEAN") # returns FALSE (argument is invalid) checkarg("Y", "BOOLEAN") # returns FALSE (argument is invalid) #checkarg("Y", "BOOLEAN", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters checkarg(1, "NUMBER", default = 0) # returns 1 (argument is returned if provided, i.e. not NULL, and valid) checkarg(NULL, "NUMBER", default = 0) # returns 0 (default is returned since argument is not provided) checkarg(NULL, "NUMBER", default = 0) # returns 0 (default is returned since argument is not provided) checkarg(NA, "NUMBER") # returns FALSE (NA values are not allowed by default) checkarg(NA, "NUMBER", naAllowed = TRUE) # returns TRUE (NA values are allowed) checkarg(c(0, 1), "NUMBER") # returns FALSE (scalar value expected by default) checkarg(c(0, 1), "NUMBER", n = NA) # returns TRUE (any length vector allowed) checkarg("X", "STRING") # returns TRUE (argument is valid) checkarg(TRUE, "STRING") # returns FALSE (argument is invalid) checkarg(1, "STRING") # returns FALSE (argument is invalid)
checkarg(TRUE, "BOOLEAN") # returns TRUE (argument is valid) checkarg(FALSE, "BOOLEAN") # returns TRUE (argument is valid) checkarg(1, "BOOLEAN") # returns FALSE (argument is invalid) checkarg("Y", "BOOLEAN") # returns FALSE (argument is invalid) #checkarg("Y", "BOOLEAN", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters checkarg(1, "NUMBER", default = 0) # returns 1 (argument is returned if provided, i.e. not NULL, and valid) checkarg(NULL, "NUMBER", default = 0) # returns 0 (default is returned since argument is not provided) checkarg(NULL, "NUMBER", default = 0) # returns 0 (default is returned since argument is not provided) checkarg(NA, "NUMBER") # returns FALSE (NA values are not allowed by default) checkarg(NA, "NUMBER", naAllowed = TRUE) # returns TRUE (NA values are allowed) checkarg(c(0, 1), "NUMBER") # returns FALSE (scalar value expected by default) checkarg(c(0, 1), "NUMBER", n = NA) # returns TRUE (any length vector allowed) checkarg("X", "STRING") # returns TRUE (argument is valid) checkarg(TRUE, "STRING") # returns FALSE (argument is invalid) checkarg(1, "STRING") # returns FALSE (argument is invalid)
Helper function for the checkarg function, called in cases the argument does not pass the check. Throws an exception if stopIfNot is TRUE.
checkargFailedHandler(default, stopIfNot, messagePattern, argumentName)
checkargFailedHandler(default, stopIfNot, messagePattern, argumentName)
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
messagePattern |
See checkarg function. |
argumentName |
See checkarg function. |
FALSE.
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isBooleanOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isBooleanOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "B", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, naAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isBooleanOrNaScalar(FALSE) # returns TRUE (argument is valid) isBooleanOrNaScalar("X") # returns FALSE (argument is invalid) #isBooleanOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaScalar(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanOrNaScalar("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaScalar(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
isBooleanOrNaScalar(FALSE) # returns TRUE (argument is valid) isBooleanOrNaScalar("X") # returns FALSE (argument is invalid) #isBooleanOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaScalar(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanOrNaScalar("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaScalar(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isBooleanOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isBooleanOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "B", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, naAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isBooleanOrNaScalarOrNull(FALSE) # returns TRUE (argument is valid) isBooleanOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isBooleanOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaScalarOrNull(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanOrNaScalarOrNull("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaScalarOrNull(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
isBooleanOrNaScalarOrNull(FALSE) # returns TRUE (argument is valid) isBooleanOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isBooleanOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaScalarOrNull(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanOrNaScalarOrNull("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaScalarOrNull(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isBooleanOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isBooleanOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "B", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, naAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isBooleanOrNaVector(FALSE) # returns TRUE (argument is valid) isBooleanOrNaVector("X") # returns FALSE (argument is invalid) #isBooleanOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaVector(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanOrNaVector("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaVector(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
isBooleanOrNaVector(FALSE) # returns TRUE (argument is valid) isBooleanOrNaVector("X") # returns FALSE (argument is invalid) #isBooleanOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaVector(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanOrNaVector("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaVector(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isBooleanOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isBooleanOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "B", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, naAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isBooleanOrNaVectorOrNull(FALSE) # returns TRUE (argument is valid) isBooleanOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isBooleanOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaVectorOrNull(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanOrNaVectorOrNull("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaVectorOrNull(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
isBooleanOrNaVectorOrNull(FALSE) # returns TRUE (argument is valid) isBooleanOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isBooleanOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaVectorOrNull(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanOrNaVectorOrNull("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanOrNaVectorOrNull(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isBooleanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isBooleanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "B", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, naAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isBooleanScalar(FALSE) # returns TRUE (argument is valid) isBooleanScalar("X") # returns FALSE (argument is invalid) #isBooleanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanScalar(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanScalar("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanScalar(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
isBooleanScalar(FALSE) # returns TRUE (argument is valid) isBooleanScalar("X") # returns FALSE (argument is invalid) #isBooleanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanScalar(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanScalar("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanScalar(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isBooleanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isBooleanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "B", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, naAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isBooleanScalarOrNull(FALSE) # returns TRUE (argument is valid) isBooleanScalarOrNull("X") # returns FALSE (argument is invalid) #isBooleanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanScalarOrNull(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanScalarOrNull("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanScalarOrNull(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
isBooleanScalarOrNull(FALSE) # returns TRUE (argument is valid) isBooleanScalarOrNull("X") # returns FALSE (argument is invalid) #isBooleanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanScalarOrNull(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanScalarOrNull("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanScalarOrNull(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isBooleanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isBooleanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "B", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, naAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isBooleanVector(FALSE) # returns TRUE (argument is valid) isBooleanVector("X") # returns FALSE (argument is invalid) #isBooleanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanVector(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanVector("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanVector(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
isBooleanVector(FALSE) # returns TRUE (argument is valid) isBooleanVector("X") # returns FALSE (argument is invalid) #isBooleanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanVector(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanVector("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanVector(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isBooleanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isBooleanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "B", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, naAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isBooleanVectorOrNull(FALSE) # returns TRUE (argument is valid) isBooleanVectorOrNull("X") # returns FALSE (argument is invalid) #isBooleanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanVectorOrNull(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanVectorOrNull("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanVectorOrNull(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
isBooleanVectorOrNull(FALSE) # returns TRUE (argument is valid) isBooleanVectorOrNull("X") # returns FALSE (argument is invalid) #isBooleanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanVectorOrNull(FALSE, default = TRUE) # returns FALSE (the argument, rather than the default, since it is not NULL) #isBooleanVectorOrNull("X", default = TRUE) # throws exception with message defined by message and argumentName parameters isBooleanVectorOrNull(NULL, default = TRUE) # returns TRUE (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrInfScalar(2) # returns TRUE (argument is valid) isIntegerOrInfScalar("X") # returns FALSE (argument is invalid) #isIntegerOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrInfScalar(2) # returns TRUE (argument is valid) isIntegerOrInfScalar("X") # returns FALSE (argument is invalid) #isIntegerOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrInfScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrInfScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrInfVector(2) # returns TRUE (argument is valid) isIntegerOrInfVector("X") # returns FALSE (argument is invalid) #isIntegerOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrInfVector(2) # returns TRUE (argument is valid) isIntegerOrInfVector("X") # returns FALSE (argument is invalid) #isIntegerOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrInfVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrInfVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNanOrInfScalar(2) # returns TRUE (argument is valid) isIntegerOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isIntegerOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNanOrInfScalar(2) # returns TRUE (argument is valid) isIntegerOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isIntegerOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNanOrInfVector(2) # returns TRUE (argument is valid) isIntegerOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isIntegerOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNanOrInfVector(2) # returns TRUE (argument is valid) isIntegerOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isIntegerOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNanScalar(2) # returns TRUE (argument is valid) isIntegerOrNanScalar("X") # returns FALSE (argument is invalid) #isIntegerOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNanScalar(2) # returns TRUE (argument is valid) isIntegerOrNanScalar("X") # returns FALSE (argument is invalid) #isIntegerOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNanScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNanScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNanVector(2) # returns TRUE (argument is valid) isIntegerOrNanVector("X") # returns FALSE (argument is invalid) #isIntegerOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNanVector(2) # returns TRUE (argument is valid) isIntegerOrNanVector("X") # returns FALSE (argument is invalid) #isIntegerOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNanVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNanVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaOrInfScalar(2) # returns TRUE (argument is valid) isIntegerOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaOrInfScalar(2) # returns TRUE (argument is valid) isIntegerOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaOrInfVector(2) # returns TRUE (argument is valid) isIntegerOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaOrInfVector(2) # returns TRUE (argument is valid) isIntegerOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaOrNanScalar(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaOrNanScalar(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaOrNanVector(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaOrNanVector(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaScalar(2) # returns TRUE (argument is valid) isIntegerOrNaScalar("X") # returns FALSE (argument is invalid) #isIntegerOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaScalar(2) # returns TRUE (argument is valid) isIntegerOrNaScalar("X") # returns FALSE (argument is invalid) #isIntegerOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaScalarOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaVector(2) # returns TRUE (argument is valid) isIntegerOrNaVector("X") # returns FALSE (argument is invalid) #isIntegerOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaVector(2) # returns TRUE (argument is valid) isIntegerOrNaVector("X") # returns FALSE (argument is invalid) #isIntegerOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerOrNaVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerOrNaVectorOrNull(2) # returns TRUE (argument is valid) isIntegerOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerScalar(2) # returns TRUE (argument is valid) isIntegerScalar("X") # returns FALSE (argument is invalid) #isIntegerScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerScalar(2) # returns TRUE (argument is valid) isIntegerScalar("X") # returns FALSE (argument is invalid) #isIntegerScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isIntegerScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerScalarOrNull(2) # returns TRUE (argument is valid) isIntegerScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerScalarOrNull(2) # returns TRUE (argument is valid) isIntegerScalarOrNull("X") # returns FALSE (argument is invalid) #isIntegerScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerVector(2) # returns TRUE (argument is valid) isIntegerVector("X") # returns FALSE (argument is invalid) #isIntegerVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerVector(2) # returns TRUE (argument is valid) isIntegerVector("X") # returns FALSE (argument is invalid) #isIntegerVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isIntegerVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isIntegerVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isIntegerVectorOrNull(2) # returns TRUE (argument is valid) isIntegerVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isIntegerVectorOrNull(2) # returns TRUE (argument is valid) isIntegerVectorOrNull("X") # returns FALSE (argument is invalid) #isIntegerVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isIntegerVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isIntegerVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isIntegerVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNanScalar(NaN) # returns TRUE (argument is valid) isNanScalar("X") # returns FALSE (argument is invalid) #isNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
isNanScalar(NaN) # returns TRUE (argument is valid) isNanScalar("X") # returns FALSE (argument is invalid) #isNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNanScalarOrNull(NaN) # returns TRUE (argument is valid) isNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
isNanScalarOrNull(NaN) # returns TRUE (argument is valid) isNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNanVector(NaN) # returns TRUE (argument is valid) isNanVector("X") # returns FALSE (argument is invalid) #isNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
isNanVector(NaN) # returns TRUE (argument is valid) isNanVector("X") # returns FALSE (argument is invalid) #isNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNanVectorOrNull(NaN) # returns TRUE (argument is valid) isNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
isNanVectorOrNull(NaN) # returns TRUE (argument is valid) isNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNaOrNanScalar(NA) # returns TRUE (argument is valid) isNaOrNanScalar("X") # returns FALSE (argument is invalid) #isNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNanScalar(NA, default = NaN) # returns NA (the argument, rather than the default, since it is not NULL) #isNaOrNanScalar("X", default = NaN) # throws exception with message defined by message and argumentName parameters isNaOrNanScalar(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
isNaOrNanScalar(NA) # returns TRUE (argument is valid) isNaOrNanScalar("X") # returns FALSE (argument is invalid) #isNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNanScalar(NA, default = NaN) # returns NA (the argument, rather than the default, since it is not NULL) #isNaOrNanScalar("X", default = NaN) # throws exception with message defined by message and argumentName parameters isNaOrNanScalar(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNaOrNanScalarOrNull(NA) # returns TRUE (argument is valid) isNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNanScalarOrNull(NA, default = NaN) # returns NA (the argument, rather than the default, since it is not NULL) #isNaOrNanScalarOrNull("X", default = NaN) # throws exception with message defined by message and argumentName parameters isNaOrNanScalarOrNull(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
isNaOrNanScalarOrNull(NA) # returns TRUE (argument is valid) isNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNanScalarOrNull(NA, default = NaN) # returns NA (the argument, rather than the default, since it is not NULL) #isNaOrNanScalarOrNull("X", default = NaN) # throws exception with message defined by message and argumentName parameters isNaOrNanScalarOrNull(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNaOrNanVector(NA) # returns TRUE (argument is valid) isNaOrNanVector("X") # returns FALSE (argument is invalid) #isNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNanVector(NA, default = NaN) # returns NA (the argument, rather than the default, since it is not NULL) #isNaOrNanVector("X", default = NaN) # throws exception with message defined by message and argumentName parameters isNaOrNanVector(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
isNaOrNanVector(NA) # returns TRUE (argument is valid) isNaOrNanVector("X") # returns FALSE (argument is invalid) #isNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNanVector(NA, default = NaN) # returns NA (the argument, rather than the default, since it is not NULL) #isNaOrNanVector("X", default = NaN) # throws exception with message defined by message and argumentName parameters isNaOrNanVector(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNaOrNanVectorOrNull(NA) # returns TRUE (argument is valid) isNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNanVectorOrNull(NA, default = NaN) # returns NA (the argument, rather than the default, since it is not NULL) #isNaOrNanVectorOrNull("X", default = NaN) # throws exception with message defined by message and argumentName parameters isNaOrNanVectorOrNull(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
isNaOrNanVectorOrNull(NA) # returns TRUE (argument is valid) isNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNanVectorOrNull(NA, default = NaN) # returns NA (the argument, rather than the default, since it is not NULL) #isNaOrNanVectorOrNull("X", default = NaN) # throws exception with message defined by message and argumentName parameters isNaOrNanVectorOrNull(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaOrNonEmptyStringScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNaOrNonEmptyStringScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, naAllowed = TRUE, emptyStringAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNaOrNonEmptyStringScalar("X") # returns TRUE (argument is valid) isNaOrNonEmptyStringScalar(1) # returns FALSE (argument is invalid) #isNaOrNonEmptyStringScalar(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringScalar("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrNonEmptyStringScalar(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringScalar(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isNaOrNonEmptyStringScalar("X") # returns TRUE (argument is valid) isNaOrNonEmptyStringScalar(1) # returns FALSE (argument is invalid) #isNaOrNonEmptyStringScalar(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringScalar("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrNonEmptyStringScalar(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringScalar(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaOrNonEmptyStringScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNaOrNonEmptyStringScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, naAllowed = TRUE, emptyStringAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNaOrNonEmptyStringScalarOrNull("X") # returns TRUE (argument is valid) isNaOrNonEmptyStringScalarOrNull(1) # returns FALSE (argument is invalid) #isNaOrNonEmptyStringScalarOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringScalarOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrNonEmptyStringScalarOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringScalarOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isNaOrNonEmptyStringScalarOrNull("X") # returns TRUE (argument is valid) isNaOrNonEmptyStringScalarOrNull(1) # returns FALSE (argument is invalid) #isNaOrNonEmptyStringScalarOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringScalarOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrNonEmptyStringScalarOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringScalarOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaOrNonEmptyStringVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNaOrNonEmptyStringVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, naAllowed = TRUE, emptyStringAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNaOrNonEmptyStringVector("X") # returns TRUE (argument is valid) isNaOrNonEmptyStringVector(1) # returns FALSE (argument is invalid) #isNaOrNonEmptyStringVector(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringVector("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrNonEmptyStringVector(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringVector(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isNaOrNonEmptyStringVector("X") # returns TRUE (argument is valid) isNaOrNonEmptyStringVector(1) # returns FALSE (argument is invalid) #isNaOrNonEmptyStringVector(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringVector("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrNonEmptyStringVector(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringVector(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaOrNonEmptyStringVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNaOrNonEmptyStringVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, naAllowed = TRUE, emptyStringAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNaOrNonEmptyStringVectorOrNull("X") # returns TRUE (argument is valid) isNaOrNonEmptyStringVectorOrNull(1) # returns FALSE (argument is invalid) #isNaOrNonEmptyStringVectorOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringVectorOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrNonEmptyStringVectorOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringVectorOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isNaOrNonEmptyStringVectorOrNull("X") # returns TRUE (argument is valid) isNaOrNonEmptyStringVectorOrNull(1) # returns FALSE (argument is invalid) #isNaOrNonEmptyStringVectorOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringVectorOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrNonEmptyStringVectorOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrNonEmptyStringVectorOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaOrStringScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNaOrStringScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, naAllowed = TRUE, emptyStringAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNaOrStringScalar("X") # returns TRUE (argument is valid) isNaOrStringScalar(1) # returns FALSE (argument is invalid) #isNaOrStringScalar(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrStringScalar("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrStringScalar(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrStringScalar(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isNaOrStringScalar("X") # returns TRUE (argument is valid) isNaOrStringScalar(1) # returns FALSE (argument is invalid) #isNaOrStringScalar(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrStringScalar("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrStringScalar(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrStringScalar(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaOrStringScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNaOrStringScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, naAllowed = TRUE, emptyStringAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNaOrStringScalarOrNull("X") # returns TRUE (argument is valid) isNaOrStringScalarOrNull(1) # returns FALSE (argument is invalid) #isNaOrStringScalarOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrStringScalarOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrStringScalarOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrStringScalarOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isNaOrStringScalarOrNull("X") # returns TRUE (argument is valid) isNaOrStringScalarOrNull(1) # returns FALSE (argument is invalid) #isNaOrStringScalarOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrStringScalarOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrStringScalarOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrStringScalarOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaOrStringVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNaOrStringVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, naAllowed = TRUE, emptyStringAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNaOrStringVector("X") # returns TRUE (argument is valid) isNaOrStringVector(1) # returns FALSE (argument is invalid) #isNaOrStringVector(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrStringVector("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrStringVector(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrStringVector(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isNaOrStringVector("X") # returns TRUE (argument is valid) isNaOrStringVector(1) # returns FALSE (argument is invalid) #isNaOrStringVector(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrStringVector("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrStringVector(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrStringVector(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaOrStringVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNaOrStringVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, naAllowed = TRUE, emptyStringAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNaOrStringVectorOrNull("X") # returns TRUE (argument is valid) isNaOrStringVectorOrNull(1) # returns FALSE (argument is invalid) #isNaOrStringVectorOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrStringVectorOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrStringVectorOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrStringVectorOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isNaOrStringVectorOrNull("X") # returns TRUE (argument is valid) isNaOrStringVectorOrNull(1) # returns FALSE (argument is invalid) #isNaOrStringVectorOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNaOrStringVectorOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNaOrStringVectorOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNaOrStringVectorOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNaScalar(NA) # returns TRUE (argument is valid) isNaScalar("X") # returns FALSE (argument is invalid) #isNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
isNaScalar(NA) # returns TRUE (argument is valid) isNaScalar("X") # returns FALSE (argument is invalid) #isNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNaScalarOrNull(NA) # returns TRUE (argument is valid) isNaScalarOrNull("X") # returns FALSE (argument is invalid) #isNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
isNaScalarOrNull(NA) # returns TRUE (argument is valid) isNaScalarOrNull("X") # returns FALSE (argument is invalid) #isNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNaVector(NA) # returns TRUE (argument is valid) isNaVector("X") # returns FALSE (argument is invalid) #isNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
isNaVector(NA) # returns TRUE (argument is valid) isNaVector("X") # returns FALSE (argument is invalid) #isNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNaVectorOrNull(NA) # returns TRUE (argument is valid) isNaVectorOrNull("X") # returns FALSE (argument is invalid) #isNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
isNaVectorOrNull(NA) # returns TRUE (argument is valid) isNaVectorOrNull("X") # returns FALSE (argument is invalid) #isNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrInfVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrInfVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNanOrInfVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNanOrInfVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNanScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNanScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNanVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNanVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaOrInfVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaOrInfVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaOrNanOrInfVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaOrNanOrInfVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaOrNanScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaOrNanScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaOrNanVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaOrNanVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaVector(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerOrNaVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerOrNaVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerOrNaVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerOrNaVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerScalar(-2) # returns TRUE (argument is valid) isNegativeIntegerScalar("X") # returns FALSE (argument is invalid) #isNegativeIntegerScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeIntegerScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerVector(-2) # returns TRUE (argument is valid) isNegativeIntegerVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerVector(-2) # returns TRUE (argument is valid) isNegativeIntegerVector("X") # returns FALSE (argument is invalid) #isNegativeIntegerVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeIntegerVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeIntegerVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeIntegerVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeIntegerVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeIntegerVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeIntegerVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeIntegerVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeIntegerVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeIntegerVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrInfVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrInfVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNanOrInfVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNanOrInfVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNanScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNanScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNanVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNanVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaOrInfVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaOrInfVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaOrNanOrInfVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaOrNanOrInfVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaOrNanScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaOrNanScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaOrNanVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaOrNanVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaScalar(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaVector(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaVector("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberOrNaVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberOrNaVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberOrNaVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberOrNaVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberScalar(-2) # returns TRUE (argument is valid) isNegativeNumberScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberScalar(-2) # returns TRUE (argument is valid) isNegativeNumberScalar("X") # returns FALSE (argument is invalid) #isNegativeNumberScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNegativeNumberScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberScalarOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberScalarOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberVector(-2) # returns TRUE (argument is valid) isNegativeNumberVector("X") # returns FALSE (argument is invalid) #isNegativeNumberVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberVector(-2) # returns TRUE (argument is valid) isNegativeNumberVector("X") # returns FALSE (argument is invalid) #isNegativeNumberVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNegativeNumberVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNegativeNumberVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNegativeNumberVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isNegativeNumberVectorOrNull(-2) # returns TRUE (argument is valid) isNegativeNumberVectorOrNull("X") # returns FALSE (argument is invalid) #isNegativeNumberVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNegativeNumberVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isNegativeNumberVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isNegativeNumberVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonEmptyStringScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonEmptyStringScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, naAllowed = FALSE, emptyStringAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonEmptyStringScalar("X") # returns TRUE (argument is valid) isNonEmptyStringScalar(1) # returns FALSE (argument is invalid) #isNonEmptyStringScalar(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonEmptyStringScalar("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNonEmptyStringScalar(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNonEmptyStringScalar(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isNonEmptyStringScalar("X") # returns TRUE (argument is valid) isNonEmptyStringScalar(1) # returns FALSE (argument is invalid) #isNonEmptyStringScalar(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonEmptyStringScalar("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNonEmptyStringScalar(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNonEmptyStringScalar(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonEmptyStringScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonEmptyStringScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, naAllowed = FALSE, emptyStringAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonEmptyStringScalarOrNull("X") # returns TRUE (argument is valid) isNonEmptyStringScalarOrNull(1) # returns FALSE (argument is invalid) #isNonEmptyStringScalarOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonEmptyStringScalarOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNonEmptyStringScalarOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNonEmptyStringScalarOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isNonEmptyStringScalarOrNull("X") # returns TRUE (argument is valid) isNonEmptyStringScalarOrNull(1) # returns FALSE (argument is invalid) #isNonEmptyStringScalarOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonEmptyStringScalarOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNonEmptyStringScalarOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNonEmptyStringScalarOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonEmptyStringVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonEmptyStringVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, naAllowed = FALSE, emptyStringAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonEmptyStringVector("X") # returns TRUE (argument is valid) isNonEmptyStringVector(1) # returns FALSE (argument is invalid) #isNonEmptyStringVector(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonEmptyStringVector("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNonEmptyStringVector(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNonEmptyStringVector(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isNonEmptyStringVector("X") # returns TRUE (argument is valid) isNonEmptyStringVector(1) # returns FALSE (argument is invalid) #isNonEmptyStringVector(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonEmptyStringVector("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNonEmptyStringVector(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNonEmptyStringVector(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonEmptyStringVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonEmptyStringVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, naAllowed = FALSE, emptyStringAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonEmptyStringVectorOrNull("X") # returns TRUE (argument is valid) isNonEmptyStringVectorOrNull(1) # returns FALSE (argument is invalid) #isNonEmptyStringVectorOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonEmptyStringVectorOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNonEmptyStringVectorOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNonEmptyStringVectorOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isNonEmptyStringVectorOrNull("X") # returns TRUE (argument is valid) isNonEmptyStringVectorOrNull(1) # returns FALSE (argument is invalid) #isNonEmptyStringVectorOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonEmptyStringVectorOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isNonEmptyStringVectorOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isNonEmptyStringVectorOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrInfVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrInfVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNanOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNanOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNanOrInfVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNanOrInfVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNanScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNanScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNanScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNanScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNanVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNanVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNanVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNanVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaOrInfVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaOrInfVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaOrNanScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaOrNanScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaOrNanVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaOrNanVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaVector(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerOrNaVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerOrNaVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerScalar(2) # returns TRUE (argument is valid) isNonZeroIntegerScalar("X") # returns FALSE (argument is invalid) #isNonZeroIntegerScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroIntegerScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerVector(2) # returns TRUE (argument is valid) isNonZeroIntegerVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerVector(2) # returns TRUE (argument is valid) isNonZeroIntegerVector("X") # returns FALSE (argument is invalid) #isNonZeroIntegerVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroIntegerVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroIntegerVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroIntegerVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroIntegerVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroIntegerVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroIntegerVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroIntegerVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroIntegerVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrInfVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrInfVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNanOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNanOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNanOrInfVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNanOrInfVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNanScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNanScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNanScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNanScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNanVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNanVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNanVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNanVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaOrInfVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaOrInfVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaOrNanScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaOrNanScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaOrNanVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaOrNanVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaScalar(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaVector(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberOrNaVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberOrNaVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberScalar(2) # returns TRUE (argument is valid) isNonZeroNumberScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberScalar(2) # returns TRUE (argument is valid) isNonZeroNumberScalar("X") # returns FALSE (argument is invalid) #isNonZeroNumberScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNonZeroNumberScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberScalarOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberScalarOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberVector(2) # returns TRUE (argument is valid) isNonZeroNumberVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberVector(2) # returns TRUE (argument is valid) isNonZeroNumberVector("X") # returns FALSE (argument is invalid) #isNonZeroNumberVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNonZeroNumberVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNonZeroNumberVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNonZeroNumberVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNonZeroNumberVectorOrNull(2) # returns TRUE (argument is valid) isNonZeroNumberVectorOrNull("X") # returns FALSE (argument is invalid) #isNonZeroNumberVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNonZeroNumberVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNonZeroNumberVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNonZeroNumberVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrInfScalar(2) # returns TRUE (argument is valid) isNumberOrInfScalar("X") # returns FALSE (argument is invalid) #isNumberOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrInfScalar(2) # returns TRUE (argument is valid) isNumberOrInfScalar("X") # returns FALSE (argument is invalid) #isNumberOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrInfVector(2) # returns TRUE (argument is valid) isNumberOrInfVector("X") # returns FALSE (argument is invalid) #isNumberOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrInfVector(2) # returns TRUE (argument is valid) isNumberOrInfVector("X") # returns FALSE (argument is invalid) #isNumberOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNanOrInfScalar(2) # returns TRUE (argument is valid) isNumberOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNumberOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNanOrInfScalar(2) # returns TRUE (argument is valid) isNumberOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNumberOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNanOrInfVector(2) # returns TRUE (argument is valid) isNumberOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNumberOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNanOrInfVector(2) # returns TRUE (argument is valid) isNumberOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNumberOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNanScalar(2) # returns TRUE (argument is valid) isNumberOrNanScalar("X") # returns FALSE (argument is invalid) #isNumberOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNanScalar(2) # returns TRUE (argument is valid) isNumberOrNanScalar("X") # returns FALSE (argument is invalid) #isNumberOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNanScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNanScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNanVector(2) # returns TRUE (argument is valid) isNumberOrNanVector("X") # returns FALSE (argument is invalid) #isNumberOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNanVector(2) # returns TRUE (argument is valid) isNumberOrNanVector("X") # returns FALSE (argument is invalid) #isNumberOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNanVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNanVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaOrInfScalar(2) # returns TRUE (argument is valid) isNumberOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isNumberOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaOrInfScalar(2) # returns TRUE (argument is valid) isNumberOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isNumberOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaOrInfVector(2) # returns TRUE (argument is valid) isNumberOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isNumberOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaOrInfVector(2) # returns TRUE (argument is valid) isNumberOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isNumberOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isNumberOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isNumberOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isNumberOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isNumberOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaOrNanScalar(2) # returns TRUE (argument is valid) isNumberOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaOrNanScalar(2) # returns TRUE (argument is valid) isNumberOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaOrNanVector(2) # returns TRUE (argument is valid) isNumberOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaOrNanVector(2) # returns TRUE (argument is valid) isNumberOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaScalar(2) # returns TRUE (argument is valid) isNumberOrNaScalar("X") # returns FALSE (argument is invalid) #isNumberOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaScalar(2) # returns TRUE (argument is valid) isNumberOrNaScalar("X") # returns FALSE (argument is invalid) #isNumberOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaScalarOrNull(2) # returns TRUE (argument is valid) isNumberOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaVector(2) # returns TRUE (argument is valid) isNumberOrNaVector("X") # returns FALSE (argument is invalid) #isNumberOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaVector(2) # returns TRUE (argument is valid) isNumberOrNaVector("X") # returns FALSE (argument is invalid) #isNumberOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberOrNaVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberOrNaVectorOrNull(2) # returns TRUE (argument is valid) isNumberOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberScalar(2) # returns TRUE (argument is valid) isNumberScalar("X") # returns FALSE (argument is invalid) #isNumberScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberScalar(2) # returns TRUE (argument is valid) isNumberScalar("X") # returns FALSE (argument is invalid) #isNumberScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isNumberScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberScalarOrNull(2) # returns TRUE (argument is valid) isNumberScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberScalarOrNull(2) # returns TRUE (argument is valid) isNumberScalarOrNull("X") # returns FALSE (argument is invalid) #isNumberScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberVector(2) # returns TRUE (argument is valid) isNumberVector("X") # returns FALSE (argument is invalid) #isNumberVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberVector(2) # returns TRUE (argument is valid) isNumberVector("X") # returns FALSE (argument is invalid) #isNumberVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isNumberVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isNumberVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = TRUE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isNumberVectorOrNull(2) # returns TRUE (argument is valid) isNumberVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isNumberVectorOrNull(2) # returns TRUE (argument is valid) isNumberVectorOrNull("X") # returns FALSE (argument is invalid) #isNumberVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isNumberVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isNumberVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isNumberVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrInfScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrInfScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrInfVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrInfVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNanOrInfScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNanOrInfScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNanOrInfVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNanOrInfVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNanScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNanScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNanScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNanScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNanVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNanVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNanVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNanVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaOrInfScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaOrInfScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaOrInfVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaOrInfVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaOrNanScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaOrNanScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaOrNanVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaOrNanVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaScalar(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaVector(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerOrNaVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerOrNaVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerScalar(2) # returns TRUE (argument is valid) isPositiveIntegerScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerScalar(2) # returns TRUE (argument is valid) isPositiveIntegerScalar("X") # returns FALSE (argument is invalid) #isPositiveIntegerScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveIntegerScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerScalarOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerVector(2) # returns TRUE (argument is valid) isPositiveIntegerVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerVector(2) # returns TRUE (argument is valid) isPositiveIntegerVector("X") # returns FALSE (argument is invalid) #isPositiveIntegerVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveIntegerVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveIntegerVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveIntegerVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveIntegerVectorOrNull(2) # returns TRUE (argument is valid) isPositiveIntegerVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveIntegerVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveIntegerVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveIntegerVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveIntegerVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrInfScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrInfScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrInfVector(2) # returns TRUE (argument is valid) isPositiveNumberOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrInfVector(2) # returns TRUE (argument is valid) isPositiveNumberOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNanOrInfScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNanOrInfScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNanOrInfVector(2) # returns TRUE (argument is valid) isPositiveNumberOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNanOrInfVector(2) # returns TRUE (argument is valid) isPositiveNumberOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNanScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrNanScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNanScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrNanScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNanScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNanScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNanVector(2) # returns TRUE (argument is valid) isPositiveNumberOrNanVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNanVector(2) # returns TRUE (argument is valid) isPositiveNumberOrNanVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNanVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNanVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaOrInfScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaOrInfScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaOrInfVector(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaOrInfVector(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaOrNanScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaOrNanScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaOrNanVector(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaOrNanVector(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrNaScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaScalar(2) # returns TRUE (argument is valid) isPositiveNumberOrNaScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaVector(2) # returns TRUE (argument is valid) isPositiveNumberOrNaVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaVector(2) # returns TRUE (argument is valid) isPositiveNumberOrNaVector("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberOrNaVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberOrNaVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberScalar(2) # returns TRUE (argument is valid) isPositiveNumberScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberScalar(2) # returns TRUE (argument is valid) isPositiveNumberScalar("X") # returns FALSE (argument is invalid) #isPositiveNumberScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isPositiveNumberScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberScalarOrNull(2) # returns TRUE (argument is valid) isPositiveNumberScalarOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberVector(2) # returns TRUE (argument is valid) isPositiveNumberVector("X") # returns FALSE (argument is invalid) #isPositiveNumberVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberVector(2) # returns TRUE (argument is valid) isPositiveNumberVector("X") # returns FALSE (argument is invalid) #isPositiveNumberVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isPositiveNumberVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isPositiveNumberVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isPositiveNumberVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isPositiveNumberVectorOrNull(2) # returns TRUE (argument is valid) isPositiveNumberVectorOrNull("X") # returns FALSE (argument is invalid) #isPositiveNumberVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isPositiveNumberVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isPositiveNumberVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isPositiveNumberVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNanOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNanOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNanScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNanScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNanVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNanVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaOrNanOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaOrNanOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaOrNanScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaOrNanScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaOrNanVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaOrNanVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerOrNaVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerOrNaVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerOrNaVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerOrNaVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeIntegerVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeIntegerVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeIntegerVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeIntegerVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeIntegerVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeIntegerVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeIntegerVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeIntegerVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNanOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNanOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNanScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNanScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNanVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNanVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaOrNanOrInfScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanOrInfScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaOrNanOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaOrNanOrInfVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanOrInfVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanOrInfVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaOrNanScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaOrNanScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaOrNanScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaOrNanVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaOrNanVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaOrNanVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaOrNanVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaOrNanVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberOrNaVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberOrNaVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberOrNaVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberOrNaVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberScalar(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberScalar("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberScalar(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberScalar("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberScalar(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberScalarOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberScalarOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberScalarOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberScalarOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberVector(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberVector("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberVector(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberVector("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberVector(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyNegativeNumberVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyNegativeNumberVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = TRUE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyNegativeNumberVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
isStrictlyNegativeNumberVectorOrNull(-2) # returns TRUE (argument is valid) isStrictlyNegativeNumberVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyNegativeNumberVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberVectorOrNull(-2, default = -1) # returns -2 (the argument, rather than the default, since it is not NULL) #isStrictlyNegativeNumberVectorOrNull("X", default = -1) # throws exception with message defined by message and argumentName parameters isStrictlyNegativeNumberVectorOrNull(NULL, default = -1) # returns -1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNanOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNanOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNanOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNanOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNanScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNanScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNanScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNanScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNanVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNanVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNanVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNanVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaOrNanScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaOrNanScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaOrNanVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaOrNanVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerOrNaVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerOrNaVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerVector(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveIntegerVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveIntegerVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = FALSE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveIntegerVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveIntegerVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveIntegerVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveIntegerVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveIntegerVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveIntegerVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNanOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNanOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNanOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNanOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNanScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNanScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNanScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNanScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNanVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNanVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNanVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNanVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaOrNanOrInfScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaOrNanOrInfScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanOrInfScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanOrInfScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanOrInfScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaOrNanOrInfVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaOrNanOrInfVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanOrInfVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanOrInfVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanOrInfVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanOrInfVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaOrNanScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaOrNanScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaOrNanScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaOrNanVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaOrNanVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaOrNanVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaOrNanVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaOrNanVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberOrNaVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberOrNaVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberOrNaVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberOrNaVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberScalar(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberScalar("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberScalar(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberScalar("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberScalar(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberScalarOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberScalarOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberScalarOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberScalarOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberScalarOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberVector(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberVector("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberVector(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberVector("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberVector(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStrictlyPositiveNumberVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStrictlyPositiveNumberVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = FALSE, negativeAllowed = FALSE, positiveAllowed = TRUE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isStrictlyPositiveNumberVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
isStrictlyPositiveNumberVectorOrNull(2) # returns TRUE (argument is valid) isStrictlyPositiveNumberVectorOrNull("X") # returns FALSE (argument is invalid) #isStrictlyPositiveNumberVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberVectorOrNull(2, default = 1) # returns 2 (the argument, rather than the default, since it is not NULL) #isStrictlyPositiveNumberVectorOrNull("X", default = 1) # throws exception with message defined by message and argumentName parameters isStrictlyPositiveNumberVectorOrNull(NULL, default = 1) # returns 1 (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStringScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStringScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, naAllowed = FALSE, emptyStringAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStringScalar("X") # returns TRUE (argument is valid) isStringScalar(1) # returns FALSE (argument is invalid) #isStringScalar(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStringScalar("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isStringScalar(1, default = "Y") # throws exception with message defined by message and argumentName parameters isStringScalar(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isStringScalar("X") # returns TRUE (argument is valid) isStringScalar(1) # returns FALSE (argument is invalid) #isStringScalar(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStringScalar("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isStringScalar(1, default = "Y") # throws exception with message defined by message and argumentName parameters isStringScalar(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStringScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isStringScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, naAllowed = FALSE, emptyStringAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStringScalarOrNull("X") # returns TRUE (argument is valid) isStringScalarOrNull(1) # returns FALSE (argument is invalid) #isStringScalarOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStringScalarOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isStringScalarOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isStringScalarOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isStringScalarOrNull("X") # returns TRUE (argument is valid) isStringScalarOrNull(1) # returns FALSE (argument is invalid) #isStringScalarOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStringScalarOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isStringScalarOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isStringScalarOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStringVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStringVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, naAllowed = FALSE, emptyStringAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStringVector("X") # returns TRUE (argument is valid) isStringVector(1) # returns FALSE (argument is invalid) #isStringVector(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStringVector("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isStringVector(1, default = "Y") # throws exception with message defined by message and argumentName parameters isStringVector(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isStringVector("X") # returns TRUE (argument is valid) isStringVector(1) # returns FALSE (argument is invalid) #isStringVector(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStringVector("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isStringVector(1, default = "Y") # throws exception with message defined by message and argumentName parameters isStringVector(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isStringVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isStringVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "S", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, naAllowed = FALSE, emptyStringAllowed = TRUE, message = message, argumentName = argumentName)
See checkarg function.
isStringVectorOrNull("X") # returns TRUE (argument is valid) isStringVectorOrNull(1) # returns FALSE (argument is invalid) #isStringVectorOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStringVectorOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isStringVectorOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isStringVectorOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
isStringVectorOrNull("X") # returns TRUE (argument is valid) isStringVectorOrNull(1) # returns FALSE (argument is invalid) #isStringVectorOrNull(1, stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isStringVectorOrNull("X", default = "Y") # returns "X" (the argument, rather than the default, since it is not NULL) #isStringVectorOrNull(1, default = "Y") # throws exception with message defined by message and argumentName parameters isStringVectorOrNull(NULL, default = "Y") # returns "Y" (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isZeroOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroOrNanScalar(0) # returns TRUE (argument is valid) isZeroOrNanScalar("X") # returns FALSE (argument is invalid) #isZeroOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNanScalar(0, default = NaN) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNanScalar("X", default = NaN) # throws exception with message defined by message and argumentName parameters isZeroOrNanScalar(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
isZeroOrNanScalar(0) # returns TRUE (argument is valid) isZeroOrNanScalar("X") # returns FALSE (argument is invalid) #isZeroOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNanScalar(0, default = NaN) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNanScalar("X", default = NaN) # throws exception with message defined by message and argumentName parameters isZeroOrNanScalar(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isZeroOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroOrNanScalarOrNull(0) # returns TRUE (argument is valid) isZeroOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isZeroOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNanScalarOrNull(0, default = NaN) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNanScalarOrNull("X", default = NaN) # throws exception with message defined by message and argumentName parameters isZeroOrNanScalarOrNull(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
isZeroOrNanScalarOrNull(0) # returns TRUE (argument is valid) isZeroOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isZeroOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNanScalarOrNull(0, default = NaN) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNanScalarOrNull("X", default = NaN) # throws exception with message defined by message and argumentName parameters isZeroOrNanScalarOrNull(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isZeroOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroOrNanVector(0) # returns TRUE (argument is valid) isZeroOrNanVector("X") # returns FALSE (argument is invalid) #isZeroOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNanVector(0, default = NaN) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNanVector("X", default = NaN) # throws exception with message defined by message and argumentName parameters isZeroOrNanVector(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
isZeroOrNanVector(0) # returns TRUE (argument is valid) isZeroOrNanVector("X") # returns FALSE (argument is invalid) #isZeroOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNanVector(0, default = NaN) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNanVector("X", default = NaN) # throws exception with message defined by message and argumentName parameters isZeroOrNanVector(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isZeroOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroOrNanVectorOrNull(0) # returns TRUE (argument is valid) isZeroOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isZeroOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNanVectorOrNull(0, default = NaN) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNanVectorOrNull("X", default = NaN) # throws exception with message defined by message and argumentName parameters isZeroOrNanVectorOrNull(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
isZeroOrNanVectorOrNull(0) # returns TRUE (argument is valid) isZeroOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isZeroOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNanVectorOrNull(0, default = NaN) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNanVectorOrNull("X", default = NaN) # throws exception with message defined by message and argumentName parameters isZeroOrNanVectorOrNull(NULL, default = NaN) # returns NaN (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isZeroOrNaOrNanScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroOrNaOrNanScalar(0) # returns TRUE (argument is valid) isZeroOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isZeroOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanScalar(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaOrNanScalar("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanScalar(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
isZeroOrNaOrNanScalar(0) # returns TRUE (argument is valid) isZeroOrNaOrNanScalar("X") # returns FALSE (argument is invalid) #isZeroOrNaOrNanScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanScalar(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaOrNanScalar("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanScalar(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isZeroOrNaOrNanScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroOrNaOrNanScalarOrNull(0) # returns TRUE (argument is valid) isZeroOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isZeroOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanScalarOrNull(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaOrNanScalarOrNull("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanScalarOrNull(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
isZeroOrNaOrNanScalarOrNull(0) # returns TRUE (argument is valid) isZeroOrNaOrNanScalarOrNull("X") # returns FALSE (argument is invalid) #isZeroOrNaOrNanScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanScalarOrNull(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaOrNanScalarOrNull("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanScalarOrNull(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isZeroOrNaOrNanVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroOrNaOrNanVector(0) # returns TRUE (argument is valid) isZeroOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isZeroOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanVector(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaOrNanVector("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanVector(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
isZeroOrNaOrNanVector(0) # returns TRUE (argument is valid) isZeroOrNaOrNanVector("X") # returns FALSE (argument is invalid) #isZeroOrNaOrNanVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanVector(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaOrNanVector("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanVector(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isZeroOrNaOrNanVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = TRUE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroOrNaOrNanVectorOrNull(0) # returns TRUE (argument is valid) isZeroOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isZeroOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanVectorOrNull(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaOrNanVectorOrNull("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanVectorOrNull(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
isZeroOrNaOrNanVectorOrNull(0) # returns TRUE (argument is valid) isZeroOrNaOrNanVectorOrNull("X") # returns FALSE (argument is invalid) #isZeroOrNaOrNanVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanVectorOrNull(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaOrNanVectorOrNull("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaOrNanVectorOrNull(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isZeroOrNaScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroOrNaScalar(0) # returns TRUE (argument is valid) isZeroOrNaScalar("X") # returns FALSE (argument is invalid) #isZeroOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaScalar(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaScalar("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaScalar(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
isZeroOrNaScalar(0) # returns TRUE (argument is valid) isZeroOrNaScalar("X") # returns FALSE (argument is invalid) #isZeroOrNaScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaScalar(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaScalar("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaScalar(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isZeroOrNaScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroOrNaScalarOrNull(0) # returns TRUE (argument is valid) isZeroOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isZeroOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaScalarOrNull(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaScalarOrNull("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaScalarOrNull(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
isZeroOrNaScalarOrNull(0) # returns TRUE (argument is valid) isZeroOrNaScalarOrNull("X") # returns FALSE (argument is invalid) #isZeroOrNaScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaScalarOrNull(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaScalarOrNull("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaScalarOrNull(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isZeroOrNaVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroOrNaVector(0) # returns TRUE (argument is valid) isZeroOrNaVector("X") # returns FALSE (argument is invalid) #isZeroOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaVector(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaVector("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaVector(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
isZeroOrNaVector(0) # returns TRUE (argument is valid) isZeroOrNaVector("X") # returns FALSE (argument is invalid) #isZeroOrNaVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaVector(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaVector("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaVector(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isZeroOrNaVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = TRUE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroOrNaVectorOrNull(0) # returns TRUE (argument is valid) isZeroOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isZeroOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaVectorOrNull(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaVectorOrNull("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaVectorOrNull(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
isZeroOrNaVectorOrNull(0) # returns TRUE (argument is valid) isZeroOrNaVectorOrNull("X") # returns FALSE (argument is invalid) #isZeroOrNaVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters isZeroOrNaVectorOrNull(0, default = NA) # returns 0 (the argument, rather than the default, since it is not NULL) #isZeroOrNaVectorOrNull("X", default = NA) # throws exception with message defined by message and argumentName parameters isZeroOrNaVectorOrNull(NULL, default = NA) # returns NA (the default, rather than the argument, since it is NULL)
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isZeroScalar(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroScalar(0) # returns TRUE (argument is valid) isZeroScalar("X") # returns FALSE (argument is invalid) #isZeroScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
isZeroScalar(0) # returns TRUE (argument is valid) isZeroScalar("X") # returns FALSE (argument is invalid) #isZeroScalar("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
isZeroScalarOrNull(argument, default = NULL, stopIfNot = FALSE, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = 1, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroScalarOrNull(0) # returns TRUE (argument is valid) isZeroScalarOrNull("X") # returns FALSE (argument is invalid) #isZeroScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
isZeroScalarOrNull(0) # returns TRUE (argument is valid) isZeroScalarOrNull("X") # returns FALSE (argument is invalid) #isZeroScalarOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isZeroVector(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = FALSE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroVector(0) # returns TRUE (argument is valid) isZeroVector("X") # returns FALSE (argument is invalid) #isZeroVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
isZeroVector(0) # returns TRUE (argument is valid) isZeroVector("X") # returns FALSE (argument is invalid) #isZeroVector("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
This function can be used in 3 ways:
Return TRUE or FALSE depending on whether the argument checks are
passed. This is suitable e.g. for if statements that take further action
if the argument does not pass the checks.
Throw an exception if the argument does not pass the checks. This is
suitable e.g. when no further action needs to be taken other than
throwing an exception if the argument does not pass the checks.
Same as (2) but by supplying a default value, a default can be assigned
in a single statement, when the argument is NULL. The checks are still
performed on the returned value, and an exception is thrown when not
passed.
isZeroVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
isZeroVectorOrNull(argument, default = NULL, stopIfNot = FALSE, n = NA, message = NULL, argumentName = NULL)
argument |
See checkarg function. |
default |
See checkarg function. |
stopIfNot |
See checkarg function. |
n |
See checkarg function. |
message |
See checkarg function. |
argumentName |
See checkarg function. |
Actual call to checkarg: checkarg(argument, "N", default = default, stopIfNot = stopIfNot, nullAllowed = TRUE, n = NA, zeroAllowed = TRUE, negativeAllowed = FALSE, positiveAllowed = FALSE, nonIntegerAllowed = TRUE, naAllowed = FALSE, nanAllowed = FALSE, infAllowed = FALSE, message = message, argumentName = argumentName)
See checkarg function.
isZeroVectorOrNull(0) # returns TRUE (argument is valid) isZeroVectorOrNull("X") # returns FALSE (argument is invalid) #isZeroVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters
isZeroVectorOrNull(0) # returns TRUE (argument is valid) isZeroVectorOrNull("X") # returns FALSE (argument is invalid) #isZeroVectorOrNull("X", stopIfNot = TRUE) # throws exception with message defined by message and argumentName parameters