Ocean Color Forum - Not logged in
Forum Ocean Color Home Help Search Login
Previous Next Up Topic SeaDAS / SeaDAS 6.x - General Questions / batch script (locked) (1933 hits)
By adogliotti Date 2008-04-24 18:40
Hi,

I'm trying to execute a very simple batch script load_image.batch

seadisp & $
load,'/DADOS/SeaDAS/A2006301171000.L2_LAC',prod_name=['chlor_a'] & $
display, band_no=1,/GEO, FBUF=1 & $
loadpal, 13 & $
coast, color=7 & $
out, 'A2006301171000_chl.png', /display, ftype='png', /cbar, bk_cbar=1  & $
clear_up & $

then I run
seadas -em -b load_image.batch

and I get this error message:

"! The following error was encountered: Attempt to subscript SDSEX_CMDS with SDSEX_BLIX is out of range. Please consult the supplier of the application"

I've run much complicated scripts before and never got this message.
Can you help me?
Thanks in advance.

Ana
By mike Date 2008-04-24 19:33 Edited 2008-04-24 19:36
The problem is that your last line has the "$" line continuation character. To make the script work just change the last line to be:

  clear_up

And the only time you need to place the "& $" characters at the end of lines is for a loop. seadisp is also defunct. So your script would be better written as:

  load,'/DADOS/SeaDAS/A2006301171000.L2_LAC',prod_name=['chlor_a']
  display, band_no=1,/GEO, FBUF=1
  loadpal, 13
  coast, color=7
  out, 'A2006301171000_chl.png', /display, ftype='png', /cbar, bk_cbar=1
  clear_up

An example of using a loop in your script with the "& $" characters would be:

  load,'/DADOS/SeaDAS/A2006301171000.L2_LAC',prod_name=['chlor_a']
  display, band_no=1,/GEO, FBUF=1
  loadpal, 13
  coast, color=7
  out, 'A2006301171000_chl.png', /display, ftype='png', /cbar, bk_cbar=1
  for i=1,3 do begin & $
    print,'Example loop iteration number:', i  & $
  endfor
  clear_up
By adogliotti Date 2008-04-24 19:49
Thank you Mike!

It's true, I wrote many scripts, but always using a loop for choosing the input files.
Thanks

Ana
Previous Next Up Topic SeaDAS / SeaDAS 6.x - General Questions / batch script (locked) (1933 hits)



Responsible NASA Official: Gene C. Feldman
Curator: OceanColor Webmaster
Authorized by: Gene C. Feldman
Updated: 27 November 2007
Privacy Policy and Important Notices NASA logo