Understanding the Interactive Matrix Language |
A matrix literal is a matrix represented by its values. When you represent a matrix with a literal, you are simply specifying the values of each element of the matrix. A matrix literal can have a single element (a scalar), or it can have many elements arranged in a rectangular form (rows columns). The matrix can be numeric (all elements are numeric) or character (all elements are character). The dimension of the matrix is automatically determined by the way you punctuate the values.
If there are multiple elements, you use braces ({ }) to enclose the values and commas to separate the rows. Within the braces, values must be either all numeric or all character. If you use commas to create multiple rows, all rows must have the same number of elements (columns).
The values you input can be any of the following:
Copyright © 2009 by SAS Institute Inc., Cary, NC, USA. All rights reserved.