You can use geom_text to add text positioned in data units, or
grid.text to add text positioned in absolute units.
Hadley
> --
> You received this message because you are subscribed to the ggplot2 mailing list.
> Please provide a reproducible example: http://gist.github.com/270442
>
> To post: email ggp...@googlegroups.com
> To unsubscribe: email ggplot2+u...@googlegroups.com
> More options: http://groups.google.com/group/ggplot2
>
--
Assistant Professor / Dobelman Family Junior Chair
Department of Statistics / Rice University
http://had.co.nz/
Not with geom_text, but you have total control if you use grid.
There's a good example in the R graphics book.
Hadley
library(ggExtra)
# and version 0.6.5 of gridExtra
p = qplot(1:2, 1:2) + theme_bw()
d <- data.frame(my.values = c( "x=12", "y=1.34"))
p + annotate("table", x=1.2, y=1.5, table=d, just=c("left", "top"),
theme=theme.list(show.box = TRUE, separator = "black",
show.csep = TRUE, show.rsep = TRUE, show.colnames=T))
HTH,
baptiste
but after I decompress the file and replace it in my library, it
still says that the version is 0.6.1 (sessionInfo()) and the new function
to apply the argument just=c("left","top") doesn't work
The code will also get transferred to r-forge by tomorrow, and if it
passes the checks there (as it should) I'll update the CRAN version
too.
baptiste