Hi,
Here's the relevant parts of the code:
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
times = wrf_user_list_times(a)
time = (/72,78,102/)
t = 0
it = time(t)
QB = wrf_user_getvar(a,"QBUOY",it)
Cld = wrf_user_getvar(a,"CLDFRA",it)
Z = wrf_user_getvar(a,"z",it)
lats = wrf_user_getvar(a, "lat",it)
lons = wrf_user_getvar(a, "lon",it)
Slat = new((/3/),"float")
Slon = new((/3/),"float")
Elat = new((/3/),"float")
Elon = new((/3/),"float")
do j = 0, 2
Slat(j) = lat_T(129 - time(j) + 6)
Elat(j) = lat_T(129 - time(j) - 6)
Slon(j) = lon_T(129 - time(j) + 6)
Elon(j) = lon_T(129 - time(j) - 6)
end do
;---------------------------------------- General Resources--------------------------------------------
res = True
res@gsnStringFont = 25
res@tiMainOn = False
; res@tiMainFont = 25
; res@tiMainFontHeightF = 0.03
res@tmBorderLineColor = "grey43"
res@tmBorderThicknessF = 1.0
res@gsnFrame = False
res@gsnDraw = False
res@vpWidthF = 0.7
res@vpHeightF = .16
res@tiYAxisFont = 25
res@tiYAxisFontHeightF = 0.03
res@tmYLMinorOn = False
res@tmYLLabelFontHeightF = 0.02
res@tmYMajorGrid = True
res@tmYMajorGridLineColor = "grey70"
res@tmYMajorGridLineDashPattern = 2
res@tmYMajorGridThicknessF = 0.5
res@tmYLLabelFont = 25
res@tmYROn = False
res@tmYLMajorLineColor = "grey43"
res@tmYLMajorThicknessF = 1.0
res@tmYLLabelDeltaF = -0.6
res@trXMinF = 0
res@trXMaxF = 120
res@tmXMajorGrid = True
res@tmXBMajorLengthF = 0.005
res@tmXMajorGridLineColor = "grey70"
res@tmXMajorGridLineDashPattern = 2
res@tmXMajorGridThicknessF = 0.5
res@tmXBMinorOn = True
res@tmXTOn = False
res@tmXBMajorLineColor = "grey43"
res@tmXBMajorThicknessF = 1.0
res@gsnStringFontHeightF = 0.022
res@gsnCenterStringOrthogonalPosF = -0.05
res@cnLineLabelsOn = False
res@cnInfoLabelOn = False
res@gsnMaximize = True
res@trYMinF = 0
res@trYMaxF = 1500
res@tiYAxisString = ""
res@tmYLMode = "Explicit"
res@tmYLDataBottomF = 0
res@tmYLDataTopF = 1500
res@tmYLValues = fspan(0,1500,4)
res@tmYLMinorOn = False
res@tmYLLabels = sprintf("%4.0f",fspan(0,1500,4))
;----------------------------------------------------------------------------------
opt = True
start_lat = Slat(0)
end_lat = Elat(0)
start_lon = Slon(0)
end_lon = Elon(0)
opt@latlon = True
opt@linecoords = True
opt@file_handle = a
QBa = wrf_user_unstagger(QB, QB@stagger)
plane_plot = wrf_user_vert_cross(Cld40,:,,Z40,:,,(/start_lon, start_lat, end_lon, end_lat/),opt)
plane_plotII = wrf_user_vert_cross(QBa40,:,,Z40,:,,(/start_lon, start_lat, end_lon, end_lat/),opt)
;--------------------------------------------------- QB Plot ------------------------------------------------------------
resDw = res
cmapI = read_colormap_file("NCV_blue_red")
resDw@cnFillOn = True
resDw@cnFillMode = "RasterFill"
resDw@cnRasterSmoothingOn = True
resDw@cnFillPalette = cmapI(CMP_min:CMP_max,
resDw@cnLinesOn = False
resDw@cnLabelBarEndStyle = "IncludeMinMaxLabels"
resDw@lbOrientation = "vertical"
resDw@pmLabelBarWidthF = 0.06
resDw@pmLabelBarHeightF = 0.16
resDw@pmLabelBarOrthogonalPosF = 0
resDw@pmLabelBarParallelPosF = 0.5
resDw@lbLabelFontHeightF = 0.02
resDw@lbLabelFont = 25
resDw@lbAutoManage = False
resDw@cnExplicitLabelBarLabelsOn = True
resDw@lbLabelAutoStride = False
resDw@lbBoxLinesOn = False
resDw@lbLabelStrings = sprintf("%5.2f",fspan(MIN_val,MAX_val,tot_cm))
resDw@lbLabelStride = STR ;3*decimalPlaces(tot_cm/10,0,False)
resDw@cnLevelSelectionMode = "ExplicitLevels"
resDw@cnLevels = fspan(MIN_val,MAX_val,tot_cm)
;--------------------------------------- CLD plot ---------------------------------------------------
resFc = True
resFc@gsnDraw = False
resFc@gsnFrame = False
cmap2 = read_colormap_file("precip2_17lev")
resFc@cnFillOn = False
resFc@cnLinePalette = cmap2
resFc@cnMonoLineColor = False
resFc@cnLinesOn = True ; Line contours
; resFc@cnLineColor = "black"
resFc@cnLineLabelsOn = False
resFc@cnLineThicknessF = 1.5
resFc@cnInfoLabelOn = False
resFc@cnLevelSelectionMode = "ExplicitLevels"
resFc@cnLevels = fspan(min(Cld
40,:,
),max(Cld
40,:,
),11)
xvalues = ispan(0,dimsizes(plane_plotII(0,)-1,1)
ll_step = 40
resDw@tmXBMode = "Explicit"
resDw@tmXBValues = xvalues:ll_step)
resDw@tmXBLabels = sprintf("%6.2f",plane_plotII@lats:ll_step)) + "~S~o~N~N~C~" + \
sprintf("%6.2f",plane_plotII@lons:ll_step)) + "~S~o~N~E"
resDw@tmXBLabelFontHeightF = 0.01
resDw@tmXBLabelAngleF = 45.
plotII = gsn_csm_contour(wks,plane_plotII,resDw)
plotI = gsn_csm_contour(wks,plane_plot,resFc)
overlay(plotII, plotI)
draw(plotII)
frame(wks)
end
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Please disregard CMP_min, CMP_max, MIN_val, MAX_val, and tot_cm. They are calculated from plane_plot and plane_plotII and only determine the range of colors used in the contour plots. The relevant parts of the code are in bold.
I should also note that the plot I previously attached is created using the exact same code for W (vertical velocity) instead of QB but has the same gap in the first layer.
Thank you so much for your help,