Re: translating an array name to a string [message #22154 is a reply to message #22153] |
Thu, 19 October 2000 00:00   |
Alex Schuster
Messages: 124 Registered: February 1997
|
Senior Member |
|
|
David Williams wrote:
> Hi. This is probably a very basic IDL question, so apologies if that's
> the case. I'm looking for a way to translate the name of an array (e.g.
> "DATACUBE1") into a string that I can use in titles and/or in feedback
> at the prompt. I want to make my routines more user-friendly, and I hate
> forcing a title
Have a look at the OUTPUT keyword to HELP:
IDL> help, movie
MOVIE BYTE = Array[256, 256, 64]
IDL> help, movie, output=output
IDL> print, output
MOVIE BYTE = Array[256, 256, 64]
CLU> print, (str_sep( output[0], " "))[0]
MOVIE
Alex
--
Alex Schuster Wonko@weird.cologne.de PGP Key available
alex@pet.mpin-koeln.mpg.de
|
|
|