Check function arguments type.
Syntax
ERR = errargt(NDFCT,VAR,TYPE)
ERR = errargt(NDFCT,VAR,'msg')
Description
errargn is a general utility.
ERR = errargt(NDFCT,VAR,TYPE) is equal to 1 if any element of input vector or matrix VAR (depending on TYPE choice listed below) is not of type prescribed by input string TYPE. Otherwise ERR = 0.
If ERR = 1, an error message is displayed in the command window. In the header message, the string NDFCT is displayed. This string contains the name of a function.
Available options for TYPE are:
'int'
|
Strictly positive integers (excluding zero)
|
'in0'
|
Positive integers (including zero)
|
'rel'
|
Integers
|
'rep'
|
Strictly positive reals (excluding zero)
|
're0'
|
Positive reals (including zero)
|
'str'
|
String
|
'vec'
|
Vector
|
'row'
|
Row vector
|
'col'
|
Column vector
|
'dat'
|
Dates AAAAMMJJHHMNSS with:

|
'mon'
|
Months MM with: 
|
A special use of errargt is:
ERR = errargt(NDFCT,VAR,'msg') for which ERR = 1 and the string VAR is the error message.
See Also
errargn
[ Previous | Help Desk | Next ]