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

Home » Public Forums » archive » Re: eh..a question about idl...i really need some help
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: eh..a question about idl...i really need some help [message #77810] Sat, 08 October 2011 23:14
i's_can is currently offline  i's_can
Messages: 2
Registered: October 2011
Junior Member
On Oct 6, 3:16 am, David Fanning <n...@dfanning.com> wrote:
> Kane Earnest writes:
>> when i come to the astronomy user's library, it halted at one program
>> at
>
>> lambda = Varray (min(filter_w), max(filter_w), 1000.)
>
>> the error message is that
>
>> % Compiled module: $MAIN$.
>> % Variable is undefined: VARRAY.
>> % Execution halted at: $MAIN$
>
>> i want to know what does this line mean,and how to correct it
>
> I suppose it means IDL thinks Varray is a variable,
> rather than a function. You can "fix" it by making
> sure you only use parentheses for function calls
> and not for array subscripting. You do this by adding
> the compiler option strictarr to the top of the program
> module where you are having problems (in other words, *all*
> of them!).
>
>    compile_opt strictarr
>
> Cheers,
>
> David
>
> --
> David Fanning, Ph.D.
> Fanning Software Consulting, Inc.
> Coyote's Guide to IDL Programming:http://www.idlcoyote.com/
> Sepore ma de ni thui. ("Perhaps thou speakest truth.")

thank you , David
i have tried to add the line you said,but it doesn't work

sorry for making a mistake in express my question,in fact,i just wanna
know
lambda = Varray (min(filter_w), max(filter_w), 1000.)
what the programer wanna get by this line in the quote

i checked the window for variable,both the VARRAY & LAMBDA are
undefined....
Re: eh..a question about idl...i really need some help [message #77819 is a reply to message #77810] Fri, 07 October 2011 00:45 Go to previous message
Nikola is currently offline  Nikola
Messages: 53
Registered: November 2009
Member
Is your astro library in the path? Probably not.

Cheers, NV
Re: eh..a question about idl...i really need some help [message #77826 is a reply to message #77819] Wed, 05 October 2011 12:16 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Kane Earnest writes:

> when i come to the astronomy user's library, it halted at one program
> at
>
> lambda = Varray (min(filter_w), max(filter_w), 1000.)
>
> the error message is that
>
> % Compiled module: $MAIN$.
> % Variable is undefined: VARRAY.
> % Execution halted at: $MAIN$
>
> i want to know what does this line mean,and how to correct it

I suppose it means IDL thinks Varray is a variable,
rather than a function. You can "fix" it by making
sure you only use parentheses for function calls
and not for array subscripting. You do this by adding
the compiler option strictarr to the top of the program
module where you are having problems (in other words, *all*
of them!).

compile_opt strictarr

Cheers,

David



--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: Non Nom on the Memory
Next Topic: printing with a format in exponent!

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

Current Time: Wed Oct 08 15:21:33 PDT 2025

Total time taken to generate the page: 0.00397 seconds