[ncl-talk] contour labels
Marston Ward
marston.johnston at gu.se
Tue Apr 10 06:01:02 MDT 2018
Hey Adam,
Thanks for the tips and apologies for the late reply.
I’ve solved this by removing the labels altogether.
Cheers,
/M
On 5 Apr 2018, at 18:40, Adam Phillips <asphilli at ucar.edu<mailto:asphilli at ucar.edu>> wrote:
Hi Marston,
Take a look at examples #3, 5, 6 and 7 on the contour labels examples page here:
http://www.ncl.ucar.edu/Applications/contourLab.shtml
I've had success with the strategies shown in both #3 and #5.
Hope that helps!
Adam
On Wed, Apr 4, 2018 at 9:42 AM, Marston Ward <marston.johnston at gu.se<mailto:marston.johnston at gu.se>> wrote:
Hi,
I’m trying to get the contour labels to show up on each contour as well as control the size of the labels so that the labels do not cross many contours.
But I’m not getting this to work with the following resource setup:
wksd := gsn_open_wks ("png",oname)
info_string = "IWP: 0 to .4 by .1"
cnres = True
cnres at gsnDraw = False
cnres at gsnFrame = False
cnres at cnLinesOn = True
cnres at cnLineColor = "DarkOrchid4"
cnres at cnFillOn = False
cnres at cnLineLabelsOn = True
cnres at cnLineThicknessF = 2.0
cnres at cnLineLabelBackgroundColor= -1 ; transparent
cnres at cnInfoLabelOrthogonalPosF = -0.25 ; Move into plot
;cnres at cnLineLabelInterval = 1
;cnres at cnLineLabelFontHeightF = 0.0001
cnres at cnInfoLabelString = info_string
cnres at cnInfoLabelFontColor = "DarkOrchid4"
cnres at cnInfoLabelPerimOn = False
cnres at tfDoNDCOverlay = True ; Line up four axes of both plots.
cnres at cnLevelSelectionMode = "ManualLevels" ; set manual contour levels
cnres at cnMinLevelValF = 0. ; set min contour level
cnres at cnMaxLevelValF = .4 ; set max contour level
cnres at cnLevelSpacingF = .1 ; set contour spacing
cnres at tiYAxisString = “"
cnres at tiXAxisString = “"
I’m using the above resource to create overlays on contour plots that will be a panel plot, for example:
plotd(0) = gsn_csm_contour_map_overlay(wksd,p(0,:,:),iwp,resd,cnres)
However, I cannot get the labels to change change to a smaller size or show up on ever contour, of which there are 5 possible, given the max, min, and spacing.
Would love to get some help with this if anyone has an idea what part of the resource above is incorrect or missing additional information.
Best,
/Marston
_______________________________________________
ncl-talk mailing list
ncl-talk at ucar.edu<mailto:ncl-talk at ucar.edu>
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
--
Adam Phillips
Associate Scientist, Climate and Global Dynamics Laboratory, NCAR
www.cgd.ucar.edu/staff/asphilli/<http://www.cgd.ucar.edu/staff/asphilli/> 303-497-1726
<http://www.cgd.ucar.edu/staff/asphilli>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20180410/986ff5b3/attachment.html>
More information about the ncl-talk
mailing list