- 积分
- 3652
- 贡献
-
- 精华
- 在线时间
- 小时
- 注册时间
- 2015-4-22
- 最后登录
- 1970-1-1
|
登录后查看更多精彩内容~
您需要 登录 才可以下载或查看,没有帐号?立即注册
x
本帖最后由 felin 于 2017-10-1 10:58 编辑
之后我尝试把画plot的绘图设置在重新画一遍,即从
bres=True
。。。至
plot = gsn_csm_contour_map(wks,dif,bres)
再复制画一次(当然要改成res和plot1)
后面还是opt = True不变,结果就画出来了。问题解决但
至于为什么之前没画出填色图的问题,不清楚。。。
*****************************************
请大家帮忙看看我用ncl画图的脚本,只画plot时,填色图是存在的,但是一旦加上 plot1 = gsn_contour_shade(plot, -0.15,0.15, opt) 这一句,画的图就只有点,没有填色图了,如下!同时也试过overlay把两张图重一起,也还是只有点没填色图。
请问这是为什么,怎么改呢?
;**************************************************
; create plots
;************************************************
wks = gsn_open_wks("ps","diff") ; send graphics to PS file
gsn_define_colormap(wks,"ncl_default") ; choose colormap
bres=True
bres@gsnSpreadColors = True ; use full range of colormap
bres@gsnDraw = False
bres@gsnFrame = False
bres@gsnAddCyclic = False
bres@cnFillOn = True ; color plot desired
bres@cnLinesOn = False ; turn off contour lines
bres@cnLineLabelsOn = False ; turn off contour labels
bres@cnLevelSelectionMode = "ExplicitLevels"
bres@cnLevels = (/-0.2,-0.15,-0.1,-0.05,0,0.05,0.1,0.15,0.2/)
bres@mpMinLatF = 18
bres@mpMaxLatF = 53.5
bres@mpMinLonF = 72
bres@mpMaxLonF = 135.5
bres@pmTickMarkDisplayMode = "Always"
bres@mpFillOn = False
bres@mpDataSetName = "/public/home/***/NCL/lib/ncarg/database/Earth..4"
bres@mpDataBaseVersion = "MediumRes" ; or "Ncarg4_1"
bres@mpAreaMaskingOn = True
bres@mpMaskAreaSpecifiers = (/"China"/)
bres@mpOutlineSpecifiers = (/"China","China:Provinces"/)
bres@mpFillDrawOrder = "PostDraw"
bres@mpFillOn = True
bres@mpFillAreaSpecifiers = (/"water", "land" /)
bres@mpSpecifiedFillColors = (/"white", "white"/)
bres@tmXTOn = False
bres@tmXTLabelsOn = False
bres@tmXTMinorOn = False
bres@tmYROn = False
bres@tmYRLabelsOn = False
bres@tmYRMinorOn = False
bres@mpUSStateLineThicknessF = 2.0
bres@mpGeophysicalLineThicknessF = 2.0
bres@mpNationalLineThicknessF = 2.0
bres@tfDoNDCOverlay = True
plot = gsn_csm_contour_map(wks,dif,bres)
opt = True
opt@gsnShadeFillType = "pattern" ; pattern fill
opt@gsnShadeLow = 17
opt@gsnShadeHigh = 17 ; use pattern #17
opt@cnLineLabelsOn = True
plot1 = gsn_contour_shade(plot, -0.15,0.15, opt)
draw(plot1)
frame(wks)
|
|