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

Home » Public Forums » archive » undefined keyword variables
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: undefined keyword variables [message #17613 is a reply to message #17531] Mon, 01 November 1999 00:00 Go to previous messageGo to previous message
Paul Hick is currently offline  Paul Hick
Messages: 9
Registered: November 1999
Junior Member
In IDL5.2 several other plot keywords show the same behaviour as clip:

position, [xyz]margin, [xyz]range, [xyz]tickname, [xyz]tickv

I reported this to RSI a while back. In IDL5.3 (I'm running the Windows
beta version) this has been fixed. Presumably now the values from system
variables (!p.position, !x.margin, etc.) are used if the keyword
variable
is undefined.

Mark Fardal wrote:
>
> Hi,
>
> A question: should you always be able to pass undefined variables as
> keywords to IDL routines?
>
> For example, PLOT is smart enough not to do anything with this undefined
> variable
>
> IDL> plot,x,y,title=donkeykong
> [plots fine]
>
> but not this one
> IDL> plot,x,y,clip=pong
> % PLOT: Variable is undefined: PONG.
> % Execution halted at: $MAIN$
> [no plot produced]
>
> IDL> help,donkeykong, pong
> DONKEYKONG UNDEFINED = <Undefined>
> PONG UNDEFINED = <Undefined>
>
> Should this be considered a bug in plot, or as normal behavior?
>
> In general I don't know why you should be able to safely feed
> undefined variables to routines and expect them to work. But if you
> can't, it leads to annoying problems in writing interfaces to any
> routine with lots of keywords. In my case, I wanted to write a
> routine that called plot and then oplot, which use different sets of
> optional keyword parameters. The best solution I know of is to
> construct a value for the _extra keyword, but it's a pretty convoluted
> solution.
>
> Mark Fardal
> UMass
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Can this be vectorized?
Next Topic: change widget slider maximum dynamically?

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

Current Time: Sat Oct 11 06:09:37 PDT 2025

Total time taken to generate the page: 1.35847 seconds