-
Notifications
You must be signed in to change notification settings - Fork 37
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
Using richtext with annotate() #8
Comments
Thank you! |
Thanks, this should work now. Going forward, please remove any unneeded code from your reprex, to focus on the key issue (see my example below). Also, I strongly suggest using the reprex package. It makes your life easier while making certain your examples are truly reproducible. library(ggplot2)
library(ggtext)
ggplot(iris, aes(Sepal.Length, Sepal.Width, color = Species)) +
geom_point(size = 3) +
annotate(geom='richtext', x=8, y=4, label='<i>potential outlier?</i>') +
coord_cartesian(clip = "off") Created on 2019-11-27 by the reprex package (v0.3.0) |
Sorry about that (I will limit the examples to minimum), but I cannot get reprex working for me (it was working in RStudio on my old PC, but because it was not updated for Ubuntu 19.10 and install fails with security issues I had to give up; then I was fighting with getting reprex to display the markdown instead of rendering in the browser, but could not - there are issues open for these problems already). I am only saying that it is not so easy for everyone to make use of reprex as it may seem, despite an honest effort and an hour less of my time spend on fighting with it :( |
I have tried using the
geom_richtext
withannotate
in two ways, both of which failed:or
with:
Error: Can't find `geom` called "(geom_)richtext"
and
with:
If this is just an unexplored corner case (and not something which would require a lot of work), this could be very useful to have. A full example:
The text was updated successfully, but these errors were encountered: