;************************************************ load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl" load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl" load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl" ;************************************************ begin ;************************************************ ; make sure myfile is specified on the command line ;************************************************ if (.not.isvar("myfile")) then print("required variable myfile omitted on the command line") exit end if if (.not.isvar("wksType")) then wksType = "ncgm" end if ;************************************************ ; create pointer to file and read in data ;************************************************ in = addfile(myfile,"r") lev = in->lv_ISBL0 klev = dimsizes(lev) ;************************************************ ; open workstation ;************************************************ wks = gsn_open_wks(wksType, myfile) ; open a ps file gsn_define_colormap(wks,"BlAqGrYeOrRe") ; choose colormap res = True ; plot mods desired res@cnFillOn = True ; turn on color fill res@cnLinesOn = False ; turn off contour lines res@gsnSpreadColors = True ; use full range of color map ;************************************************ ; loop over levels ; plot Q directly ... it is not in complex form ;************************************************ do kl=2,2 ; 0,klev-1 Q = in->Q_GDS4_ISBL(kl,:,:) ; ( lv_ISBL0, g4_lat_4, g4_lon_5 ) res@tiMainString = Q@initial_time res@gsnCenterString = "P="+lev(kl) plot = gsn_csm_contour_map_ce(wks,Q,res) end do end