**** NOTE **** use portrait ****** var=p01_000120 input_title='HAFS Ensemble\PROB OF PRECIPITATION > 1 inch DURING DAY 1\Storm: DELT(26L) init 2020100700' var='p01_024048' input_title='HAFS Ensemble\PROB OF PRECIPITATION > 1 inch DURING 24-48 h\Storm: NINE(09L) init 2024092400' outfile='p01_024048.png' say 'draw 'var 'open ens_prob.ctl' 'c' 'set parea 1.0 7.5 1.4 7.9' *'set lon 'lon1' 'lon2 *'set lat 'lat1' 'lat2 'set grads off' 'set mpdset mres' 'run rgbset.gs' 'set mpt 0 79 3 3' 'set mpt 1 79 3 3' 'set mpt 2 79 3 3' 'set stat on' 'set gxout shaded' 'set xlopts 1 5 0.15' 'set ylopts 1 5 0.15' *'color 5 50 5 -kind white->lime->yellow->deeppink->red' 'color 0 1 0.1 -kind white->grainbow' *'color 0 1 0.1 -kind grainbow' * draw a faked data to draw a colorbar, in case all are badval 'd rainbow/100.0' 'draw xlab LON(degree)' 'draw ylab LAT(degree)' **'draw title 'input_title1'\'input_title2 ' Max='smax 'draw title 'input_title ** find x, y range on current displayed plot 'query gxinfo' rec3 = sublin(result,3) rec4 = sublin(result,4) xlim1 = subwrd(rec3,4) xlim2 = subwrd(rec3,6) ylim1 = subwrd(rec4,4) ylim2 = subwrd(rec4,6) say 'xlim1 = 'xlim1' ylim1 = 'ylim1 say 'xlim2 = 'xlim2' ylim2 = 'ylim2 ** draw color bar xbar=(xlim1+xlim2)/2.0 ybar=ylim1-1.0 'run cbarn 0.9 0 'xbar' 'ybar *real data 'color 0 1 0.1 -kind white->grainbow' 'd smth9('var')' stat=result line8=sublin(stat,8) smin=subwrd(line8,4) smax=subwrd(line8,5) * draw tracks of members ** member id# start_mem=0 end_mem=30 m=start_mem while(m <= end_mem) say 'm='m smem=m if(m<10) ; smem='0'm ; endif ** if(t >=10 & t<100) ; ts='0't ; endif *'set line 15 1 1' 'set line 1 1 1' *'run oplot_xy data/track_mem'smem' 3' 'run oplot_xy plot_track_mem'smem' 0' m=m+1 endwhile 'printim 'outfile' x900y900 white' ***************************************