dash.assert.matrixTypeSize
Throw error if input is not a matrix of a specified format
Syntax
Description
Checks if an input is a matrix of the required data type and size. If not, throws an error.
Customize error messages and IDs.
Input Arguments
input
any data type
The input being tested
types
string vector | []
The allowed data types of the input. Use an empty array to allow any type.
siz
vector, positive integers [2] | []
The required size of the matrix. The first element is required number of rows, and the second element is the required number of columns. Use NaN for an element to allow any size along that dimension, or use an empty array to allow any size.
name
string scalar
The name of the input for error messages. Default is “input”.
header
string scalar
Header for thrown error IDs.