<div dir="ltr"><div>Try adding following at the end, after overlay:</div><div><br></div><div>draw(plot)</div><div>frame(wks)<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Jul 31, 2019 at 7:57 AM S Br via ncl-talk <<a href="mailto:ncl-talk@ucar.edu">ncl-talk@ucar.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hello NCL,<div>I am plotting the difference between two files as per the script written below, but I want to display (contour shade) only the value that are significance at 95% level. I am able to stripe the significance difference but can't display the difference that are significant (I want to retain the original color shade of the difference)</div><div><br></div><div>diffposglob1 = avgposglobst1-avgstctrl<br></div><div>probtposglob1 = 100.*(1. -ttest(avgposglobst1,varposglobst1,50,avgstctrl,varctrl,50,True,False)) ; all areas whose value > 95 are significant<br></div><div><br></div><div>wks = gsn_open_wks("x11","surtemp_sig_diff") <br></div><div> res = True<br> res@gsnDraw = False ; don't draw<br> res@gsnFrame = False ; don't advance frame<br> res@cnFillOn = False ; turn on color<br> res@cnLinesOn = True ; turns off contour lines.<br> res@cnLineLabelsOn = False ; turn off line labels<br> res@cnFillPalette = "temp_diff_18lev" ; set color map<br> res@cnInfoLabelOn = False ; turn off cn info label explanation<br> res@lbLabelBarOn = True ; turn off individual cb's<br></div><div> res@cnLevelSelectionMode = "ManualLevels"</div> res@cnMinLevelValF = -1.5<br> res@cnMaxLevelValF = 1.5<br> res@cnLevelSpacingF = 0.3<br> res@tmXBLabelFontHeightF = 0.030 ; resize tick labels<br> res@tmYLLabelFontHeightF = 0.030<br> res@gsnStringFontHeightF = 0.030<br><div>;***********************************************************<br> res2 = True ; res2 probability plots<br> res2@gsnDraw = False ; Do not draw plot<br> res2@gsnFrame = False ; Do not advance frome<br> res2@cnInfoLabelOn = False<br> res2@cnLinesOn = False ; do not draw contour lines<br> res2@cnLineLabelsOn = False ; do not draw contour labels<br> res2@cnFillScaleF = 0.3 ; add extra density<br>; sgres@cnFillDotSizeF = 0.003<br> res2@cnLevelSelectionMode = "ExplicitLevels" ; set explicit cnlev<br> res2@cnLevels = (/95./) ; only have 1 contour level<br> res2@gsnRightString = "" ; Turn off subtitles<br> res2@gsnLeftString = ""<br> res@gsnAddCyclic = True ; add cyclic point<br>;***********************************************************<br> opt = True ; set up parameters for pattern fill<br> opt@gsnShadeFillType = "pattern" ; specify pattern fill<br> opt@gsnShadeHigh = 15 ; stipple pattern<br>; opt@gsnShadeFillScaleF = 5<br>; opt@gsnShadeDotSizeF = 1 ; make dots larger<br>;***********************************************************<br></div><div>plot = gsn_csm_contour_map(wks,diffposglob1(0,:,:),res)<br> plot2 = gsn_csm_contour(wks,probtposglob1(0,:,:),res2)<br> plot2 = gsn_contour_shade(plot2,-999,95., opt) ; stipple all areas >= 95 contour<br> overlay (plot, plot2)<br></div></div>
_______________________________________________<br>
ncl-talk mailing list<br>
<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a><br>
List instructions, subscriber options, unsubscribe:<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" rel="noreferrer" target="_blank">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a></blockquote></div>