$ y yields the shape of y as defined
in Section II A. For example,
the shape of a 2-by-3 matrix is 2 3, and the shape of
the scalar 3 is an empty list
(whose shape is 0).
The rank of an argument y is #@$ y . For example:
rank=: #@$
(rank 3) , (rank ,3)
0 1
(rank 3 4),(rank i. 2 3 4)
1 3
|
|
The shape of x$y is x,siy where siy is
the shape of an item of y; x$y gives a length error
if y is empty and x,siy does not contain a zero.
For example:
y=: 3 4$'abcdefghijkl'
y ; 2 2$ y
+----+----+
|abcd|abcd|
|efgh|efgh|
|ijkl| |
| |ijkl|
| |abcd|
+----+----+
This example shows how the result is formed from the items
of y, the last 1-cell (abcd)
showing that the selection is cyclic. The fit
conjunction ($!.f)
provides fill specified by the items of f .
|