Select rows and columns from a collelction

submatrix rows columns collection

Returns new collection composed of rows and columns selected from the input collection, rows and columns are collections of integers. Type of the returned collection is the same as the type of the input collection.

Example:

"a := {{1 2 3} {4 5 6} {7 8 9}}
print submatrix {1 3} {2 3} :a

Output:

{{2 3} {8 9}}

See also:

Table of Content