立即注册 登录
气象家园 返回首页

xlilium的个人空间 http://bbs.06climate.com/?88510 [收藏] [复制] [分享] [RSS]

留言板

facelist doodle涂鸦板

您需要登录后才可以留言 登录 | 立即注册


杰西卡·芬 2020-9-27 09:12
xlilium: 你如果不是Lambert投影,南海那的经纬度应该是用nhres@mpMinLatF 这些设置吧
谢谢你啊。还有就是我只想画中国的填色,其他地区不要。我的代码有没有问题?
杰西卡·芬 2020-9-26 11:05
res                   = True
res@gsnDraw           =False
res@gsnFrame          =False
res@mpGridAndLimbOn   = False              ; turn on lat/lon lines
  ;res@mpGridLatSpacingF = 30.               ; spacing for lat lines
   ;res@mpGridLonSpacingF = 30.               ; spacing for lon lines

res@cnFillOn          = True              ; color plot desired
res@cnFillPalette     = "BlueRed"      ; set color map
res@cnRasterSmoothingOn = True
res@cnLinesOn           =False
res@cnLineLabelsOn    = False  
res@cnSmoothingOn   =True
res@cnSmoothingDistanceF=0.00005
res@cnSmoothingTensionF=0.00005

;res@mpProjection        = "LambertConformal"
res@mpPerimOn            = False           ; turn off box around plot
res@mpMinLatF            = 13
res@mpMaxLatF            = 55
res@mpMinLonF            = minlon
res@mpMaxLonF            = maxlon

res@mpFillOn                = True
res@mpDataBaseVersion="MediumRes"
res@mpDataSetName="Earth..4"
res@mpAreaMaskingOn         = True
res@mpMaskAreaSpecifiers    = (/"China","India:Arunachal Pradesh","Taiwan","Disputed area between India and China"/)
res@mpOutlineSpecifiers     = (/"China","China:Provinces"/)       ;China:states
res@mpOutlineBoundarySets   ="National"


res@mpLandFillColor         = "0"
res@mpInlandWaterFillColor  = "0"
res@mpOceanFillColor        = "0"
res@mpOutlineOn             = True         ; Turn on map outlines
res@mpGeophysicalLineColor  ="black"
res@mpGeophysicalLineDashPattern   =0
res@mpGeophysicalLineThicknessF    =2
res@mpNationalLineColor            = "black"
res@mpNationalLineThicknessF       = 2

res@lbLabelFontHeightF  = 0.015           ; label bar font height
res@tiMainString       = "1800-1999 Precipitation"  ; add a title
contour = gsn_csm_contour_map(wks,tas_pr,res)
;chinamap=add_china_map(wks,contour,cnres)


加南海地图
;--- add South China Sea ---
nhres               =True
nhres@gsnMaximize   =False
nhres@vpHeightF     =0.15
nhres@vpWidthF      =0.15

nhres@mpRightCornerLatF =23.0
nhres@mpRightCornerLonF =123.0
nhres@mpLeftCornerLatF  =2.0
nhres@mpLeftCornerLonF  =105.0

nhres@mpGridAndLimbOn          = False
nhres@mpOutlineOn              = True
nhres@lbLabelBarOn             = False
nhres@tmXBOn                   = False
nhres@tmXTOn                   = False
nhres@tmYLOn                   = False
nhres@tmYROn                   = False
nhres@gsnLeftString            = ""
nhres@gsnRightString           = ""
nhres@cnLineLabelsOn       = False

map_nanhai = gsn_csm_contour_map(wks,tas_pr,nhres)

adres                          = True
adres@amParallelPosF           = 0.5 ; -0.5 is the left edge of the plot.0.495
adres@amOrthogonalPosF         = 0.5  ; -0.5 is the top edge of the plot.0.49
adres@amJust                   = "BottomRight"
plotnh = gsn_add_annotation(contour,map_nanhai,adres)

draw(contour)
frame(wks)
可以帮我看看代码吗?我画出来的南海地图那里是整个世界的缩小版。还有中国以外的地方都有填色,这是为什么?

Copyright ©2011-2014 bbs.06climate.com All Rights Reserved.  Powered by Discuz! (京ICP-10201084)

本站信息均由会员发表,不代表气象家园立场,禁止在本站发表与国家法律相抵触言论

返回顶部