Skip to content
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

opposite effect #4

Closed
manuel-delverme opened this issue Aug 10, 2016 · 5 comments
Closed

opposite effect #4

manuel-delverme opened this issue Aug 10, 2016 · 5 comments

Comments

@manuel-delverme
Copy link

for point, label in zip(embed, labs):
    notes.append(plt.text(point[0], point[1], label, bbox={'pad':0, 'alpha':0}, size=5))
adjust_text(notes, arrowprops=dict(arrowstyle="->", color='r'))

plot

i expected the exact opposite result!

@Phlya
Copy link
Owner

Phlya commented Aug 10, 2016

You were right to expect the opposite effect! I've never encountered this,
could you create a minimal reproducible example? I'll then try it later.

10 Авг 2016 г. 13:06 пользователь "Manuel" notifications@github.com
написал:

for point, label in zip(embed, labs):
notes.append(plt.text(point[0], point[1], label, bbox={'pad':0, 'alpha':0}, size=5))
adjust_text(notes, arrowprops=dict(arrowstyle="->", color='r'))

[image: plot]
https://cloud.githubusercontent.com/assets/1309922/17552941/5a1f140a-5f03-11e6-9124-ad704302547a.png

i expected the exact opposite result!


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
#4, or mute the thread
https://github.com/notifications/unsubscribe-auth/ACwsusYof8vqH3cj-2O4CKOay3UOUpn_ks5qeb6pgaJpZM4JhEse
.

@manuel-delverme
Copy link
Author

@Phlya
Copy link
Owner

Phlya commented Aug 10, 2016

Ok, thanks! I'm away from a computer now, but could you try running the
plt.scatter before adjust_text? I think now your axes aren't set up when
you do it, so maybe that's the problem.

10 Авг 2016 г. 16:25 пользователь "Manuel" notifications@github.com
написал:

https://gist.github.com/manuel-delverme/0a4610a981f0f92c1685a74a4fce1feb

[image: figure_1]
https://cloud.githubusercontent.com/assets/1309922/17559669/62a78f82-5f1f-11e6-9ffd-13d8cc0a9f3a.png


You are receiving this because you commented.
Reply to this email directly, view it on GitHub
#4 (comment), or mute
the thread
https://github.com/notifications/unsubscribe-auth/ACwsuqWx4ZsBMrsfiqIn6Gc5IC4TkhLgks5qee1XgaJpZM4JhEse
.

@Phlya
Copy link
Owner

Phlya commented Aug 10, 2016

Yes, I just checked, that's definitely the issue. If you simply do that you get this:
no_opposite_effect

@Phlya
Copy link
Owner

Phlya commented Aug 10, 2016

And to make it nicer try reducing force_text, then the super long arrows become much shorter - for example with force_text=0.25:
no_opposite_effect_ft0 25

@Phlya Phlya closed this as completed Aug 10, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants