script Help
Charles Seman
Charles.Seman at NOAA.GOV
Tue Mar 17 17:29:42 EDT 2009
If you don't require a 'reinit' for each plot, you could try something
like (haven't actually tried the code below...):
'reinit'
itime.1 = '0000' ; itime.2 = '0600' ; itime.3 = '1200'
n=1
while ( n <= 3 )
itime = itime.n
'open gfsanl_3_20060805_'itime'_000.ctl'
'set z 21'
'set lat -60 90'
'set lon -180 180'
'set mpdset hires'
'set gxout shaded'
'd rh'
'draw map'
'run cbar.gs <http://cbar.gs>'
'draw title Relative Humidity Along ITCZ: 2006-08-05_'itime''
'printim 05_'itime'.png x1600 y1200'
'close 1'
n=n+1
endwhile
I hope this helps,
Chuck
Dizzle Man wrote:
> I have several NCEP data files I would like to loop in a script
> without having to open each file one by one. Any suggestions?
>
> 'reinit'
> 'open gfsanl_3_20060805_0000_000.ctl'
> 'set z 21'
> 'set lat -60 90'
> 'set lon -180 180'
> 'set mpdset hires'
> 'set gxout shaded'
> 'd rh'
> 'draw map'
> 'run cbar.gs <http://cbar.gs>'
> 'draw title Relative Humidity Along ITCZ: 2006-08-05_0000'
> 'printim 05_0000.png x1600 y1200'
>
> 'reinit'
> 'open gfsanl_3_20060805_0600_000.ctl'
> 'set z 21'
> 'set lat -60 90'
> 'set lon -180 180'
> 'set mpdset hires'
> 'set gxout shaded'
> 'd rh'
> 'draw map'
> 'run cbar.gs <http://cbar.gs>'
> 'draw title Relative Humidity Along ITCZ: 2006-08-05_0600'
> 'printim 05_0600.png x1600 y1200'
>
> 'reinit'
> 'open gfsanl_3_20060805_1200_000.ctl'
> 'set z 21'
> 'set lat -60 90'
> 'set lon -180 180'
> 'set mpdset hires'
> 'set gxout shaded'
> 'd rh'
> 'draw map'
> 'run cbar.gs <http://cbar.gs>'
> 'draw title Relative Humidity Along ITCZ: 2006-08-05_1200'
> 'printim 05_1200.png x1600 y1200'
--
Please note that Charles.Seman at noaa.gov should be considered my NOAA
email address, not cjs at gfdl.noaa.gov.
********************************************************************
Charles Seman Charles.Seman at noaa.gov
U.S. Department of Commerce / NOAA / OAR
Geophysical Fluid Dynamics Laboratory voice: (609) 452-6547
201 Forrestal Road fax: (609) 987-5063
Princeton, NJ 08540-6649 http://www.gfdl.noaa.gov/~cjs/
********************************************************************
"The contents of this message are mine personally and do not necessarily
reflect any position of the Government or NOAA."
More information about the gradsusr
mailing list