Keywords - Function groups - @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Group: Matrix Manipulation
Topic: Sorting and Counting
See also: dot paf {}

Function: []
Description: [] gives a subarray of an array.


Usage: y = x[{,...,} d1 {,d2{,...}}]
Input:
x multidimensional array
di i=1,2,... vector
Output:
y subarray of x

Example:



x=1:12

y=reshape(x,#(3,4))

y

y[2:3,1:3]

Result:



Contents of y

[1,]        1        4        7       10 

[2,]        2        5        8       11 

[3,]        3        6        9       12 

Contents of _tmp

[1,]     2     5     8 

[2,]     3     6     9 


Group: Matrix Manipulation
Topic: Sorting and Counting
See also: dot paf {}

Keywords - Function groups - @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

(C) MD*TECH Method and Data Technologies, 21.9.2000