[Thread Prev][Thread Next][Index]

Re: [ferret_users] labels outside of plot



Hi Hein,
I don't know of a setting that will do this automatically. In general when making plot labels, there is no distinction between portions of the window that are within the plot axes and outside of them. Maybe one of our long-time PPLUS experts will have a better solution, but at least you could do something along these lines.  After drawing the plot, symbols are defined that contain the limits of the plot axes in world coordinates. .
fill my_var

let xloc = [some _expression_]

let yloc = [some _expression_]

let  do_label =  `xloc gt ($ppl$xmin) and xloc lt ($ppl$xmax) and yloc gt ($ppl$ymin) and yloc lt ($ppl$ymax)`
IF `do_label` then label/user xloc, yloc, 0, 0, 0.12, label text
You could adjust these to account for the height of the label itself.  Also if the plot is a map projection, then of course this would be done somewhat differently.

Ansley

On 6/10/2013 12:20 AM, Hein Zelle wrote:
Dear Ferret users,

this is probably trivial but I can't find it - 
when I draw labels using the label command, I specify the coordinates
in "map" units (lon, lat).  This is what I want.  However, labels
outside of the plot window are not clipped.  

Is there something I can do to clip such labels?

This is useful for automatic graticule labeling (lambert plots), but
also for plot annotations where it isn't known in advance if a plot
feature is within the map window or not.  (high / low pressure
systems, storms, etcetera).

Kind regards,
     Hein



[Thread Prev][Thread Next][Index]
Contact Us
Dept of Commerce / NOAA / OAR / PMEL / Ferret

Privacy Policy | Disclaimer | Accessibility Statement