-
-
Notifications
You must be signed in to change notification settings - Fork 7.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
textcords='axes fraction' does not work for some axes ranges #1311
Comments
Confirmed... that is really weird. at |
I have a similar issue with the 'axes fraction' and 'figure fraction' when using annotate() in log-log plots. The annotations disappear when the log scales are introduced, but they're fine when using regular scales. Here's a sample of my code. plt.clf() I'm using matplotlib 0.99.3. Commenting out the set_xcale('log') parts will make the annotation appear. Thanks @tacaswell for alerting me to this bug! |
I don't think the original issue is a bug. The problem with the example code is that the xy cooridantes (not text coordinates) are given but
|
As for the second example, the same holds true, and is not a bug. If you replace with
The main misunderstanding here is that there are two xy points in an annotation: 1) a data point being annotated ( |
Well, that is embarrassing.... Looking at this again, what is going on in my OP is that the annotation is the equivalent of There probably should be a warning if the user sets |
When calling with certain kwarg combinations (no`xytext`, but with `textcoords`) unexpected, but correct behavior can result. See matplotlib#1311 ht to @cimarronm for sorting out what was wrong.
When calling with certain kwarg combinations (no`xytext`, but with `textcoords`) unexpected, but correct behavior can result. See matplotlib#1311 ht to @cimarronm for sorting out what was wrong.
For some axes ranges, annotations will not be drawn
ax = gca()
ax.set_ylim([0,.3])
ax.annotate('.5',(.1,.5),textcoords='axes fraction' ,weight='bold',fontsize=14 )
ax.annotate('.1',(.1,.1),textcoords='axes fraction' ,weight='bold',fontsize=14 )
draw() # only .1 will show up
ax.set_ylxm([0,3])
draw() # both will show up
May be related to issues #1310 and #403
In [17]: matplotlib.version
Out[17]: '1.2.0rc2'
QT4Agg with PyQT4
edited to add links
The text was updated successfully, but these errors were encountered: