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

Home » Public Forums » archive » Re: 2D array replicated into 3D array plane by plane
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: 2D array replicated into 3D array plane by plane [message #56005] Wed, 26 September 2007 07:49 Go to next message
Vince Hradil is currently offline  Vince Hradil
Messages: 574
Registered: December 1999
Senior Member
On Sep 26, 9:30 am, "M. Katz" <MKatz...@yahoo.com> wrote:
> I'm wondering if there's a quick way to replicate a 2D array
> into a 3D array with every xy plane being the same.
>
>> From 1D to 2D I use something like this, the outer product.
>
> xx = x # (1 + fltarr(N))
>
> This makes every row equal to x in a jiffy.
>
>> From 2D to 3D however, the methodology is not as clear.
>
> Thanks,
> M. Katz

xx = rebin(x,nx,ny,nz,/sample)
Re: 2D array replicated into 3D array plane by plane [message #56079 is a reply to message #56005] Wed, 26 September 2007 14:14 Go to previous message
M. Katz is currently offline  M. Katz
Messages: 69
Registered: May 2005
Member
xx = rebin(x,nx,ny,nz,/sample)

Brilliant! Thank you.
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: data miner with windows
Next Topic: Seasonal Variation in Trend Analysis

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

Current Time: Wed Oct 08 19:22:32 PDT 2025

Total time taken to generate the page: 0.00430 seconds