One way...
T
+-----+---+---+
|0 1 2|0 1|0 1|
|3 4 5|2 3|2 3|
| |4 5| |
+-----+---+---+
((|:&.> @: (_1&{));(_1);<) T
+-----+--+---------------+
|+---+|_1|+-----+---+---+|
||0 2|| ||0 1 2|0 1|0 1||
||1 3|| ||3 4 5|2 3|2 3||
|+---+| || |4 5| ||
| | |+-----+---+---+|
+-----+--+---------------+
amend @: ((|:&.> @: (_1&{));(_1);<) T
+-----+---+---+
|0 1 2|0 1|0 2|
|3 4 5|2 3|1 3|
| |4 5| |
+-----+---+---+
amend
0: 0&({::)@:]`(<@:(1&({::))@:])`(2&({::)@:])} ]
Another way...
(']';']';'|:') apply &.> T
+-----+---+---+
|0 1 2|0 1|0 2|
|3 4 5|2 3|1 3|
| |4 5| |
+-----+---+---+
apply
128!:2
> From: Yoel Jacobsen <[EMAIL PROTECTED]>
> To: Programming forum <[email protected]>
> Sent: Thursday, January 17, 2008 8:09:28 AM
> Subject: [Jprogramming] How to apply different verbs to a boxed sequence?
>
> Hello,
>
> I have three boxed matrices and I want to transpose only the last one.
>
> How should I do it?
>
> Is there a way for instance, to apply ;:'[ [ |:' to (i.10 10);(i. 10
> 10); i.10 10 ?
>
> Yoel
> ----------------------------------------------------------------------
> For information about J forums see
> http://www.jsoftware.com/forums.htm
>
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm