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

Home » Public Forums » archive » Re: list manipulation
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: list manipulation [message #78801 is a reply to message #78800] Sun, 18 December 2011 10:22 Go to previous messageGo to previous message
greg.addr is currently offline  greg.addr
Messages: 160
Registered: May 2007
Senior Member
Thanks for that, Vincent (and the pedagogical device wasn't wasted on me!) This extract keyword is what I need, I think - except that it doesn't work the way I hoped in my case:

IDL> a=list()
IDL> a.add,[1,2,3]
IDL> a.add,2
IDL> a.add,[3,4,5]
IDL> b=list(a,/extract)
IDL> print,b
1 2 3
2
3 4 5

I thought - ok, it thinks that's just one element, so what if I add another:

IDL> b=list(a,[1],/extract)
IDL> print,b
1 2 3
2
3 4 5
1

Still no. How would you get [1,2,3,2,3,4,5] from a?

cheers,
Greg
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: list manipulation
Next Topic: Extending or resizing array in IDL

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

Current Time: Wed Oct 08 19:29:49 PDT 2025

Total time taken to generate the page: 0.00475 seconds