Re: onedtond

From: Ekin Akoglu <ekinakoglu_at_nyahnyahspammersnyahnyah>
Date: Mon Mar 08 2010 - 04:57:28 MST

Thank you, Andrew. it was what I was looking for...

On Sat, Mar 6, 2010 at 5:21 PM, Andrew Dawson <andrew.dawson@uea.ac.uk>wrote:

> Perhaps try using 'conform_dims' (
> http://www.ncl.ucar.edu/Document/Functions/Built-in/conform_dims.shtml)
> and do something like:
>
> <http://www.ncl.ucar.edu/Document/Functions/Built-in/conform_dims.shtml>depth
> = ispan(1, 50, 1)
> dpthmatrix = conform_dims( (/ 50, 674 /), depth, (/ 0 /) )
>
> Hope that helps,
> Andrew
>
> On 6 March 2010 13:47, Ekin Akoglu <ekinakoglu@gmail.com> wrote:
>
>> Dear All,
>>
>> This may be a stupid question but I used onedtond function to replicate a
>> depth matrix of size 50 like:
>>
>> 1 2 3 ...50
>>
>> I want a matrix of 50x674 like this:
>> (0) (1) ............................. (673)
>> (0) 1 1... 1
>> (1) 2 2... 2
>> (2) 3 3... 3
>> . ... .
>> . ... .
>> (49) 50 50... 50
>>
>> But I could not manage to get this done. For remaining 674 columns it uses
>> the original matrix to expand it columnwise and when the last element of the
>> original matrix was used it starts over again from the first element. Could
>> you help me?
>>
>> Regards,
>>
>> --
>> Ekin Akoglu
>>
>> Institute of Marine Sciences
>> Middle East Technical University
>> P.O. Box 28, 33731
>> Erdemli, Mersin
>> Turkey
>>
>> Web: www.ims.metu.edu.tr
>> Email: ekin@ims.metu.edu.tr
>> Phone: +90 324 521 34 34
>> GSM: +90 506 554 03 90
>>
>> _______________________________________________
>> ncl-talk mailing list
>> List instructions, subscriber options, unsubscribe:
>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>
>>
>

-- 
Ekin Akoglu
Institute of Marine Sciences
Middle East Technical University
P.O. Box 28, 33731
Erdemli, Mersin
Turkey
Web: www.ims.metu.edu.tr
Email: ekin@ims.metu.edu.tr
Phone: +90 324 521 34 34
GSM: +90 506 554 03 90

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Mon Mar 8 04:57:37 2010

This archive was generated by hypermail 2.1.8 : Mon Mar 08 2010 - 12:07:42 MST