Matrix: Set Dimensions/values
Set matrix dimensions and XY coordinates
1. mdim ms:=MSheet1 cols:=10 rows:=10;
2. mdim c:=10 r:=10 x1:=0 x2:=9 y1:=0 y2:=9;
Please refer to the page for additional option switches when accessing the x-function from script
Display Name |
Variable Name |
I/O and Type |
Default Value |
Description |
---|---|---|---|---|
Matrix | ms |
Input/Output MatrixLayer |
|
Specifies the matrix sheet to be manipulated. |
Columns | cols |
Input int |
|
Specifies the number of columns. |
Rows | rows |
Input int |
|
Specifies the number of rows. |
First X | x1 |
Input double |
|
Specifies the value of the first X coordinate. |
Last X | x2 |
Input double |
|
Specifies the value of the last X coordinate. |
First Y | y1 |
Input double |
|
Specifies the value of the first Y coordinate. |
Last Y | y2 |
Input double |
|
Specifies the value of the last Y coordinate. |
You can use this X-Function to control the number of rows and columns and the X and Y (column and row) mapping arrangement for matrices.
Row and column numbers are positive integers. They determine the number of cells in the matrix. If a matrix is a numeric matrix, you can use this X-Function to change the dimension. However, you cannot change the dimensions for images.
The X and Y coordinates of matrix data are assumed to be evenly spaced. When you set the first and last X, the first X is mapped to the first column and the last X is mapped to the last column. The X coordinates of other columns will be linearly mapped. Similar mapping applies to rows, but the first Y and the last Y are used. For a point that corresponds to a matrix cell, its position in 3D space is determined by the X and Y coordinates of this cell, as well as the Z value that is saved in the cell. When matrix data is plotted or analyzed, the XY coordinates, instead of the row and column numbers, will be used.
Keywords:scale, calibrate, calibration