Matrix Functions |
Below is an is an alphabetical list of the matrix functions available. It's a rather long list, so we have a set of smaller lists by topic:
Extraction and Related Functions
Sparse and Packed Matrix Functions
Full List
|
Elementwise absolute value of a matrix |
|
|
Average of values |
|
|
Creates a block diagonal matrix from VECT[RECTANG] |
|
|
Concatenation of matrices |
|
|
Partitioning of matrix |
|
|
Blanchard-Quah factorization |
|
|
Cholesky factor |
|
|
Number of columns of a matrix |
|
|
Compress out rows of A where elements of V are zero |
|
|
Fill matrix with a constant value |
|
|
Correlation coefficient |
|
|
Convert correlation matrix to covariance matrix |
|
|
Cosine of each member of A |
|
|
Covariance of two arrays |
|
|
Converts a covariance matrix to correlations |
|
|
Complex matrix adjoint (conjugate transpose) |
|
|
Complex diagonal from a complex vector or 1xN rectangular |
|
|
Complex Eigen decomposition |
|
|
Complex matrix inverse |
|
|
Complex singular value decomposition |
|
|
Divides columns of A by corresponding elements in vector v |
|
|
Cholesky decomposition |
|
|
Determinant of an array |
|
|
Diagonal matrix from a 1-dimensional array |
|
|
Dimensions (# of rows and columns) of an array |
|
|
Creates a matrix which transforms to stationarity a state-space model |
|
|
Full solution for initial conditions for a state space model |
|
|
Multiplies columns of A by elements in vector v |
|
|
Duplication matrix operator (for symmetric to full size) |
|
|
(General) inverse duplication matrix operator |
|
|
Dot product of two arrays |
|
|
Eigen decomposition of symmetric array |
|
|
Elementwise exponentiation function |
|
|
Create matrix filled with a single value |
|
|
Fractiles of an array |
|
|
Generalized inverse of a matrix |
|
|
Matrix required for generalized impulse responses |
|
|
Gram-Schmidt orthonormalization |
|
|
Create identity matrix |
|
|
Sorting index for a vector |
|
|
Matrix Inner cross product |
|
|
Inverse of a matrix |
|
|
Connector (transposition) operator matrix |
|
|
Kroneker product of two arrays |
|
|
Kroneker product with identity, post multiplied |
|
|
Kroneker product, post multiplied |
|
|
Elimination matrix operator (rectangular to symmetric) |
|
|
Elimination matrix operation (rectangular to below diagonal) |
|
|
Elementwise natural log function |
|
|
Returns the log determinant of a symmetric matrix |
|
|
Inverse of packed triangular matrix |
|
|
Outer matrix product of packed triangular matrix |
|
|
Extracting entries from a sparse matrix |
|
|
Filling entries in a sparse matrix |
|
|
Location of maximum value of an array |
|
|
Get maximum value of an array |
|
|
Location of minimum value of an array |
|
|
Returns a matrix with negative values of A |
|
|
Get minimum value of an array |
|
|
Matrix quadratic form operation |
|
|
Diagonal of matrix quadratic form |
|
|
Create a scalar matrix |
|
|
Markov switching transition probability transform |
|
|
Markov switching transition probability transform |
|
|
Sum of the squared elements of a matrix or vector |
|
|
Column null space |
|
|
Creates a matrix with all elements equal to one |
|
|
Matrix outer cross product |
|
|
Extract parameters from a PARMSET |
|
|
Put vector into a PARMSET |
|
|
Replaces NA’s in A with entries from B |
|
|
Replaces NA’s in A with zeros |
|
|
Returns a matrix forming basis for null space of A |
|
|
Returns a matrix with positive values of A |
|
|
Diagonalizer matrix for a symmetric |
|
|
General Cholesky factorization |
|
|
Stationary solution for initializing state space model |
|
|
Copy values from one array into another |
|
|
Copy values from one vector into another |
|
|
Puts information from an array into an array of series |
|
|
Quadratic form |
|
|
Diagonal quadratic form |
|
|
Quadratic form using an inverted matrix. |
|
|
QR decomposition |
|
|
Random normal draw |
|
|
Ranks the elements of a matrix |
|
|
Rectangular of random normal draws |
|
|
Random multivariate normal draw |
|
|
Returns a random draw from a multivariate t distribution |
|
|
Random draw on unit sphere |
|
|
Random Wishart matrix |
|
|
Random Wishart given a covariance matrix |
|
|
Random inverse Wishart matrix |
|
|
Reshapes matrix to different dimensions |
|
|
Number of rows in a matrix |
|
|
Residual sum of squares from cross-product matrix |
|
|
First element of a matrix |
|
|
Creates a sequence of real numbers |
|
|
Creates a sequence of real numbers |
|
|
Sum of squared multivariate error matrix from CMOM |
|
|
Sin of each member of A |
|
|
Size (number of elements) of an array |
|
|
Skew-symmetric matrix operator |
|
|
Solve linear equations |
|
|
Sorts an array |
|
|
Sorts an array based on the values in a column |
|
|
Sorts an array based on values in multiple columns |
|
|
Elementwise square root |
|
|
Stereo projection |
|
|
Sum of array elements |
|
|
Sum columns to create vector |
|
|
Sum rows to create vector |
|
|
Singular value decomposition |
|
|
Sweep function of a matrix |
|
|
Sweep function over a list of pivots |
|
|
Sweep function over pivots in top rows |
|
|
Returns column number for packed position n |
|
|
Returns position in “packed” symmetric of element (r,c) |
|
|
Returns row number for packed position n |
|
|
Tangent of each member of A |
|
|
Test difference of two arrays |
|
|
Transpose of a matrix |
|
|
Trace of a matrix |
|
|
Creates unit vector |
|
|
Returns 1 if and only if all members of A are valid (not missing) |
|
|
Vectorizes an array |
|
|
Vectorizes a SYMMETRIC array |
|
|
Reshapes Vector to Rectangular |
|
|
Reshapes Vector to Symmetric |
|
|
Weighted fractiles |
|
|
Extract column of a matrix |
|
|
Extract diagonal from a matrix |
|
|
Extracts row of a matrix |
|
|
Extracts a rectangular block from a matrix |
|
|
Extracts a block from a vector |
|
|
Extracts information from an array of series |
|
|
Returns a matrix of zeros |
|
Cholesky factor |
|
|
Number of columns of a matrix |
|
|
Cholesky decomposition |
|
|
Create matrix filled with a single value |
|
|
Create identity matrix |
|
|
Inverse of a matrix |
|
|
Random normal draw |
|
|
Rectangular of random normal draws |
|
|
Number of rows in a matrix |
|
|
Solve linear equations |
|
|
Transpose of a matrix |
|
|
Creates unit vector |
|
|
Returns a matrix of zeros |
Size Functions (apply to any type of array)
|
Number of columns of a matrix |
|
|
Dimensions (# of rows and columns) of an array |
|
|
Number of rows in a matrix |
|
|
Size (number of elements) of an array |
|
Creates a block diagonal matrix from VECT[RECTANG] |
|
|
Concatenation of matrices |
|
|
Partitioning of matrix |
|
|
Diagonal matrix from a 1-dimensional array |
|
|
Duplication matrix operator (for symmetric to full size) |
|
|
(General) inverse duplication matrix operator |
|
|
Connector (transposition) operator matrix |
|
|
Elimination matrix operator (rectangular to symmetric) |
|
|
Elimination matrix operation (rectangular to below diagonal) |
|
|
Reshapes matrix to different dimensions |
|
|
Skew-symmetric matrix operator |
|
|
Returns column number for packed position n |
|
|
Returns position in “packed” symmetric of element (r,c) |
|
|
Returns row number for packed position n |
|
|
Vectorizes an array |
|
|
Vectorizes a SYMMETRIC |
|
|
Reshapes Vector to Rectangular |
|
|
Reshapes Vector to Symmetric |
|
|
Extract column of a matrix |
|
|
Extract diagonal from a matrix |
|
|
Extracts row of a matrix |
|
|
Extracts a rectangular block from a matrix |
|
|
Extracts a block from a vector |
|
Fill matrix with a constant value |
|
|
Create matrix filled with a single value |
|
|
Create identity matrix |
|
|
Create a scalar matrix |
|
|
Creates a matrix with all elements equal to one |
|
|
Rectangular of random normal draws |
|
|
Creates a sequence of real numbers |
|
|
Creates a sequence of real numbers |
|
|
Creates unit vector |
|
|
Returns a matrix of zeros |
These are generally fine if an elementwise calculation is simple. However, you shouldn't generally do a string of these; if an element by element calculation is more complicated, use the EWISE instruction.
|
Elementwise absolute value of a matrix |
|
|
Cosine of each member of A |
|
|
Elementwise exponentiation function |
|
|
Elementwise natural log function |
|
|
Returns a matrix with negative values of A |
|
|
Replaces NA’s in A with entries from B |
|
|
Replaces NA’s in A with zeros |
|
|
Returns a matrix with positive values of A |
|
|
Sin of each member of A |
|
|
Elementwise square root |
|
|
Tangent of each member of A |
|
Average of values |
|
|
Correlation coefficient |
|
|
Covariance of two arrays |
|
|
Determinant of an array |
|
|
Dot product of two arrays |
|
|
Fractiles of an array |
|
|
Returns the log determinant of a symmetric matrix |
|
|
Get maximum value of an array |
|
|
Get minimum value of an array |
|
|
Sum of the squared elements of a matrix or vector |
|
|
Quadratic form |
|
|
Diagonal quadratic form |
|
|
Quadratic form using an inverted matrix. |
|
|
Residual sum of squares from cross-product matrix |
|
|
First element of a matrix |
|
|
Sum of array elements |
|
|
Sum columns to create vector |
|
|
Sum rows to create vector |
|
|
Test difference of two arrays |
|
|
Trace of a matrix |
|
|
Returns 1 if and only if all members of A are valid (not missing) |
|
|
Weighted fractiles |
|
Divides columns of A by corresponding elements in vector v |
|
|
Multiplies columns of A by elements in vector v |
|
|
Matrix Inner cross product |
|
|
Kroneker product of two arrays |
|
|
Kroneker product with identity, post multiplied |
|
|
Kroneker product, post multiplied |
|
|
Outer matrix product of packed triangular matrix |
|
|
Matrix quadratic form operation |
|
|
Diagonal of matrix quadratic form |
|
|
Matrix outer cross product |
|
|
Quadratic form |
|
|
Diagonal quadratic form |
|
|
Quadratic form using an inverted matrix. |
The mathematics behind many of these is described in Matrix Decompositions.
|
Blanchard-Quah factorization |
|
|
Cholesky factor |
|
|
Complex Eigen decomposition |
|
|
Complex singular value decomposition |
|
|
Cholesky decomposition |
|
|
Eigen decomposition of symmetric array |
|
|
Matrix required for generalized impulse responses |
|
|
Gram-Schmidt orthonormalization |
|
|
Returns a matrix forming basis for null space of A |
|
|
Diagonalizer matrix for a symmetric |
|
|
General Cholesky factorization |
|
|
QR decomposition |
|
|
Singular value decomposition |
|
Fractiles of an array |
|
|
Sorting index for a vector |
|
|
Location of maximum value of an array |
|
|
Get maximum value of an array |
|
|
Location of minimum value of an array |
|
|
Get minimum value of an array |
|
|
Ranks the elements of a matrix |
|
|
Sorts an array |
|
|
Sorts an array based on the values in a column |
|
|
Sorts an array based on values in multiple columns |
|
|
Weighted fractiles |
Extraction and Related Functions
|
Compress out rows of A where elements of V are zero |
|
|
Extracting entries from a sparse matrix |
|
|
Filling entries in a sparse matrix |
|
|
Extract parameters from a PARMSET |
|
|
Put vector into a PARMSET |
|
|
Copy values from one array into another |
|
|
Copy values from one vector into another |
|
|
Puts information from an array into an array of series |
|
|
Sum columns to create vector |
|
|
Sum rows to create vector |
|
|
Extract column of a matrix |
|
|
Extract diagonal from a matrix |
|
|
Extracts row of a matrix |
|
|
Extracts a rectangular block from a matrix |
|
|
Extracts a block from a vector |
|
|
Extracts information from an array of series |
Sparse and Packed Matrix Functions
|
Compress out rows of A where elements of V are zero |
|
|
Inverse of packed triangular matrix |
|
|
Outer matrix product of packed triangular matrix |
|
|
Extracting entries from a sparse matrix |
|
|
Filling entries in a sparse matrix |
|
|
Replaces NA’s in A with entries from B |
|
|
Replaces NA’s in A with zeros |
Copyright © 2026 Thomas A. Doan