comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: swapping dimensions
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: swapping dimensions [message #41149] Wed, 29 September 2004 06:10
Karsten Rodenacker is currently offline  Karsten Rodenacker
Messages: 98
Registered: July 1997
Member
Perhaps
; a = array [a,b,c,d]
; x = array [a,b,d,c]
x=transpose(a,[0,1,3,2])
will do it.

Karsten

On Wed, 29 Sep 2004 14:59:30 +0200, maarten <user@domain.invalid> wrote:

> Hello,
>
> Is there a fast way to 'swap' dimensions of an array. Say I have an
> array [a,b,c,d], and I would like to transform it into [a,b,d,c].
> I know I can do this in a for loop using a temporary variable, but isn't
> there a commamd that does this?
>
> thanks in advance, maarten
>



--
Karsten Rodenacker
------------------------------------------------------------ -------- :-)
GSF - Forschungszentrum Institute of Biomathematics and Biometry
D-85758 Oberschleissheim Postfach 11 29
Karsten._R_odenacker@gsf.de | http://ibb.gsf.de/ | DEL _ for reply
http://ibb.gsf.de/homepage/karsten.rodenacker/
Tel: +49 89 31873401 | FAX: ..3369
[Message index]
 
Read Message
Previous Topic: swapping dimensions
Next Topic: Translucent polygons

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 23:07:31 PDT 2025

Total time taken to generate the page: 0.48142 seconds