| Group: | Matrix Manipulation |
| Topic: | General Commands |
| See also: | mix paf sort |
| Function: | index | |
| Description: | index generates a new matrix z from an old matrix x by extracting the rows of x indicated in the index vector i. |
| Usage: | y = index (x, ind) | |
| Input: | ||
| x | n x p matrix | |
| ind | k dimensional vector | |
| Output: | ||
| y | k x p matrix | |
x = #(0.1, 0.2, 0.3, 0.4) i = #(4, 3, 2, 2, 1) ( index (x, i) )'
Contents of _tmp [1,] 0.4 0.3 0.2 0.2 0.1
| Group: | Matrix Manipulation |
| Topic: | General Commands |
| See also: | mix paf sort |