hi,
I use wrfout data to draw rainfall and i can get the picture. But its map has something wrong. ( attachment)
Can anyone give me some suggestions?
Thanks.
JinQ
-- JinQ, M.S. Ocean University of China -- scripts: 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" load "$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRFUserARW.ncl" begin a = addfile("wrfout_d03_2010-09-09_12:00:00o.nc","r") type = "eps" wks = gsn_open_wks(type,"precip_all") ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; times = wrf_user_list_times(a) ; get times in the file ntimes = dimsizes(times) ; number of times in the file ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; it =57 print("Working on time: " + times(it) +" to "+times(it-48)) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; slp = wrf_user_getvar(a,"slp",it) ; slp wrf_smooth_2d( slp, 3 ) ; smooth slp rain_exp1 = wrf_user_getvar(a,"RAINNC",it) ; 0 1 2 3 (3h) rain_con1 = wrf_user_getvar(a,"RAINC",it) rain_exp2 = wrf_user_getvar(a,"RAINNC",it-48) rain_con2 = wrf_user_getvar(a,"RAINC",it-48) rain_tot1 = rain_exp1 + rain_con1 rain_tot2 = rain_exp2 + rain_con2 rain_tot = rain_tot1 - rain_tot2 rain_tot@description = "Total Precipitation" lat2d=a->XLAT(0,:,:) lon2d=a->XLONG(0,:,:) rain_tot@lat2d=lat2d rain_tot@lon2d=lon2d ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; Set some basic resources res = True res@gsnMaximize=True res@pmTickMarkDisplayMode="Always" res@mpDataSetName = "Earth..4" res@mpDataBaseVersion = "MediumRes" res@mpOutlineSpecifiers = (/"China:states","India","Taiwan"/) ; res@mpUSStateLineThicknessF=2 ;Ê¡Ïß res@mpLimitMode = "LatLon" res@mpMinLatF = 22 res@mpMaxLatF = 29 res@mpMinLonF = 115 res@mpMaxLonF = 122 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; Plotting options for Precipitation res@cnFillOn = True res@cnLinesOn =False res@cnLevelSelectionMode = "ExplicitLevels" res@cnLevels = (/ 30, 50, 70, 90, 110, 130, 150, \ 170/) res@cnFillColors = (/"White","DarkOliveGreen1", \ "DarkOliveGreen3","Chartreuse", \ "Chartreuse3","Green","ForestGreen", \ "Yellow","Orange","Red","Violet"/) res@cnInfoLabelOn = False res@cnConstFLabelOn = False contour_tot=gsn_csm_contour_map(wks, rain_tot, res) end
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
This archive was generated by hypermail 2.1.8 : Wed Jan 18 2012 - 09:21:55 MST