[ncl-talk] Set NCL to label tic marks at all beginnings and ends of map-, time series-, ..., axes?

Mary Haley haley at ucar.edu
Tue Aug 18 09:13:07 MDT 2015


Erik,

NCL is always trying to figure out how best to label the X and Y axes such
that labels don't run into each other. Sometimes it doesn't get this quite
right.

When you want more control over the labeling, use the tmXBMode / tmYLMode
resources.

In your case, I was able to do the following, to force a label on the end
axes:

  res at tmXBMode        = "Manual"
  res at tmXBTickStartF  = res at trXMinF   ; Force tickmark labelling to start
at first value

I didn't have to set "tmXBTickEndF", because NCL figured this out based on
the start value.

See the attached script for an example.  I'm going to add this to our
tickmark examples page.

--Mary


On Mon, Aug 17, 2015 at 6:22 AM, Erik J. Schaffernicht <
eschaffe at uni-koeln.de> wrote:

> How can I ask NCL to label tic marks at all *beginning* and *end* of map
> axes,  time series axes,...?
>
> I use these to plot my data:
> gsn_csm_contour()
> gsn_csm_xy()
>
> NCL put tic marks everywhere but labels only some of them. Unfortunately,
> it only labels the beginning and end of my axes "by chance", i.e. just if
> my data range fits by chance to the NCL intervals.
>
> How can I ask NCL to label in all my plots and data ranges beginnings and
> ends of my axes without having to specify these values/coordinates/tics
> manually in each script?
>
> Example:
> (a)
> My map goes from 10N to 80N.  NCL decides to label only two tics: At 30N
> and 60N.  How can I set NCL to label 10N and 80N as well?
>
> (b)
> My time series goes from 1850 to 1870.  NCL labels 1852, 1856,...,1868.
>  How do I set NCL to add labels for 1850  and 1870, i.e. start and end
> point? ...without doing it explicitly manually for each data range I like
> to plot?
>
>
>
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150818/152a6fc9/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: tm.ncl
Type: application/octet-stream
Size: 763 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150818/152a6fc9/attachment.obj 


More information about the ncl-talk mailing list