Re: Shift label positions in contour plots? [message #68162 is a reply to message #68160] |
Wed, 30 September 2009 07:57  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Charles writes:
> Using "contour", I've made a contour plot with 3 sets of contours.
> I've got them with no fills and each has a different line style. I've
> labeled the contour levels, so the value of each contour appears along
> the curves in a couple of places:
>
> contour, z0, x, y, levels=findgen(10)/10d, c_labels=findgen(10),
> c_charsize=1, ,c_line=0
> contour, z1, x, y, levels=findgen(10)/10d, c_labels=findgen(10),
> c_charsize=1, ,c_line=1, /overplot
> contour, z2, x, y, levels=findgen(10)/10d, c_labels=findgen(10),
> c_charsize=1, ,c_line=2, /overplot
>
> A sample of the plot is here: http://bit.ly/12e1Y7
>
> My problem is that the labels overlap with each other in several
> places. If the contour sets were similar enough, I would just label
> one set and imply that each label applied to all of the nearest
> curves. But each contour set is different, so I need a label on every
> contour. I'd prefer not to decrease the font size very much.
>
> My question is - it is possible to shift the positions of the labels
> along the contours using "contour" or some other routine?
It is NOT possible using the direct graphics routine CONTOUR.
You would have a great deal more control if you were to use
the object graphics routine IDLgrCONTOUR. But, there would
be a significantly longer learning curve. You might be able
to use XContour from my web page as a place to jump-start
the process:
http://www.dfanning.com/programs/xcontour.pro
XContour is *very* old. If you manage to improve it, I'd like
to hear about it. :-)
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|