Re: [Matplotlib-users] query about pyplot.text example

2010-01-03 Thread Jae-Joon Lee
How about just extending the functionality of the "annotate"? I believe it should be quite straight forward since "annotate" already support "offset points". And "points" in matplotlib is dpi independent. However, I think calling "annotate" for an offset text is a bit inconvenient for now. annota

Re: [Matplotlib-users] query about pyplot.text example

2010-01-03 Thread Eric Firing
Phillip M. Feldman wrote: > What is meant by "draw time"? When you call text(...), a Text object is created and added to a list of things (Artists) to be drawn, but no drawing occurs (unless using pyplot in interactive mode) until a draw(), show(), or savefig() command is given. That's "draw t

Re: [Matplotlib-users] query about pyplot.text example

2010-01-03 Thread Phillip M. Feldman
What is meant by "draw time"? For most purposes, I think that I'd want to specify an offset in font units (points). If offsets are specified in units of pixels, then the results would be display-dependent, and achieving display-independent results would require some additional fiddling. I wou

Re: [Matplotlib-users] query about pyplot.text example

2010-01-03 Thread John Hunter
On Sun, Jan 3, 2010 at 2:50 PM, Eric Firing wrote: > I think that allowing display units would be easy to implement (as indicated > by Ryan's example), but font or physical units would be much trickier > because they would involve draw-time determinations.  Starting by allowing > only display unit

Re: [Matplotlib-users] query about pyplot.text example

2010-01-03 Thread Eric Firing
John Hunter wrote: > On Sun, Jan 3, 2010 at 10:22 AM, Ryan May wrote: >>> the marker. It would be great if one could specify the text offsets in >>> units of the font size rather than in units of map distance. >> You can do it, it just takes a bit of knowledge about how different >> transformatio

Re: [Matplotlib-users] query about pyplot.text example

2010-01-03 Thread John Hunter
On Sun, Jan 3, 2010 at 10:22 AM, Ryan May wrote: >> the marker.  It would be great if one could specify the text offsets in >> units of the font size rather than in units of map distance. > > You can do it, it just takes a bit of knowledge about how different > transformations are used under the h

Re: [Matplotlib-users] query about pyplot.text example

2010-01-03 Thread Ryan May
On Sun, Jan 3, 2010 at 1:02 AM, Phillip M. Feldman wrote: > Ah.  It sounds as though one must consider the scale of the map, and > then choose these offsets so that the text falls near but not too near > the marker.  It would be great if one could specify the text offsets in > units of the font si

Re: [Matplotlib-users] query about pyplot.text example

2010-01-02 Thread Phillip M. Feldman
Ah. It sounds as though one must consider the scale of the map, and then choose these offsets so that the text falls near but not too near the marker. It would be great if one could specify the text offsets in units of the font size rather than in units of map distance. Thanks! Phillip Eric

Re: [Matplotlib-users] query about pyplot.text example

2010-01-02 Thread Eric Firing
Dr. Phillip M. Feldman wrote: > The online documentation at URL= > http://www.scipy.org/Cookbook/Matplotlib/Maps has an example that uses > plt.text as follows: > > plt.text(xpt+5,ypt+5,name) > > Why is the offset 5? The proj library used by Basemap transforms lon, lat to meters, so

[Matplotlib-users] query about pyplot.text example

2010-01-02 Thread Dr. Phillip M. Feldman
The online documentation at URL= http://www.scipy.org/Cookbook/Matplotlib/Maps has an example that uses plt.text as follows: plt.text(xpt+5,ypt+5,name) Why is the offset 5? -- View this message in context: http://old.nabble.com/query-about-pyplot.text-example-tp26999119p26999119.ht