- 积分
- 135
- 贡献
-
- 精华
- 在线时间
- 小时
- 注册时间
- 2013-8-7
- 最后登录
- 1970-1-1
|
登录后查看更多精彩内容~
您需要 登录 才可以下载或查看,没有帐号?立即注册
x
本帖最后由 willnot 于 2018-4-9 16:22 编辑
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/wrf/WRFUserARW.ncl"
begin
;
; The WRF ARW input file.
; This needs to have a ".nc" appended, so just do it.
a = addfile("geo_em.d01.nc","r")
; We generate plots, but what kind do we prefer?
type = "ps"
wks = gsn_open_wks(type,"ter")
; Set some basic resources
res = True
res@MainTitle = "REAL-TIME WRF"
res@Footer = False
pltres = True
ter_res = True
opts_ter = ter_res
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
FirstTime = True
FirstTimeMap = True
mdims = getfilevardimsizes(a,"P") ; get some dimension sizes for the file
nd = dimsizes(mdims)
xlat = wrf_user_getvar(a, "XLAT",0)
xlon = wrf_user_getvar(a, "XLONG",0)
ter = wrf_user_getvar(a, "HGT_M",0)
dims = dimsizes(ter)
;---------------------------------------------------------------
mpres = True
pltres = True
mpres@mpProvincialLineColor="black" ; province line color
mpres@mpProvincialLineThicknessF =3 ; province line thickness
mpres@mpDataBaseVersion="MediumRes"
mpres@mpDataSetName="./Earth..4"
mpres@mpAreaMaskingOn = True
mpres@mpMaskAreaSpecifiers = (/"China"/)
mpres@mpOutlineSpecifiers = (/"China","China:Provinces"/)
pltres@FramePlot = False
optsM = res
optsM@NoHeaderFooter = True
optsM@cnFillOn = True
optsM@lbTitleOn = False
mpres@mpNationalLineThicknessF= 4
mpres@mpGeophysicalLineThicknessF= 4
mpres@mpNationalLineColor="black"
mpres@mpGeophysicalLineColor="black"
; Plotting options for terrain
gsn_define_colormap(wks,"MPL_terrain")
opts_ter@cnFillOn = True
opts_ter@cnLevelSelectionMode = "ExplicitLevels" ; set explicit contour levels
contour_ter = wrf_contour(a,wks,ter,opts_ter)
plot = wrf_map_overlays(a,wks,(/contour_ter/),pltres,mpres)
frame(wks)
pltres@FramePlot = True
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
end
|
-
-
hgt.ncl
2.29 KB, 下载次数: 34, 下载积分: 金钱 -5
|