Syntax Error Confusion [message #55488] |
Fri, 24 August 2007 11:02 |
rchughes
Messages: 26 Registered: April 2006
|
Junior Member |
|
|
Dear All,
I'm getting a confusing syntax error that I can't seem to figure out.
I have the following code in a batch file because the idea is to call
certain routines that access the database to get the IDL variables.
The error I get is
occ2snr = REFORM(snrarray[1,*])
^
% Syntax error.
At: /export/home/rchughes/test/batch_regioncompare.pro, Line 21
I have no idea what could be the problem. One more peculiar thing is
that the 'getsnrarray' routine does not get called because the
'snrarray' variable is undefined. I'm thinking that IDL may be
wanting to compile these lines before doing the computation which
would explain why the 'snrarray' variable is undefined. But I don't
know enough about IDL to know for sure.
Here is my snippet of code: (The only thing before this is some
declaration of variables)
IF getdata THEN $
snrarray = getsnrarray(wnrange, occlist, DATESARR=time, $
/JULIAN, $
OCCS2RM=occs2rm, WAVENUMS=wavenums) && $
occ1snr = REFORM(snrarray[0,*]) && $
occ2snr = REFORM(snrarray[1,*])
Thanks,
Ryan.
|
|
|