dash.assert.defined
Throw error if numeric array contains undefined values
Syntax
Description
dash.assert.defined(X)
Throw error if X contains NaN, Inf, or complex-valued elements.
Optionally allow NaN or Inf values.
Customize thrown error IDs.
Input Arguments
X
numeric array
The array being checked
type
scalar integer
Indicates what special values are allowed
[1 (default)]: No special values are allowed
[2]: NaN values are allowed
[3]: Inf values are allowed
[4]: NaN and Inf values are allowed
name
string scalar
The name of the input in thrown error IDs
header
string scalar
Header for thrown error IDs.