Wavelet Toolbox
  Go to function:
    Search    Help Desk 
errargn    Examples   See Also

Check function arguments number.

Syntax

Description

errargn is a general utility.

err = errargn('function',numargin,argin,numargout,argout) is equal to 1 if either the number of input (argin) or output (argout) arguments of the specified function does not belong to the vector of allowed values (numargin and
numargout, respectively). Otherwise err = 0.

If err = 1, errargn displays an error message in the command window. The header of this error message contains the string 'function'.

Examples

In this example, errargn reports an improper call to function line:

Here, surf is passed the proper number of arguments, so no error message results:

See Also

errargt

[ Previous | Help Desk | Next ]