Using grid.text(),
library(ggplot2)
print(qplot(1,1), vp=viewport(height=0.8))
grid.text(0.5, unit(1,"npc") - unit(1,"line"), label="I'm (slightly)
out of here!")
HTH,
baptiste
> --
> 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
>
I would like to recreate the attached plot. My problem is that I don't
know how to specify the "7.81" in ggplot2.
Best,
Manuel
On 04/09/2010 06:20 a.m., baptiste auguie wrote:
> library(ggplot2)
> print(qplot(1,1), vp=viewport(height=0.8))
> grid.text(0.5, unit(1,"npc") - unit(1,"line"), label="I'm (slightly)
> out of here!")
--
Manuel Sp�nola, Ph.D.
Instituto Internacional en Conservaci�n y Manejo de Vida Silvestre
Universidad Nacional
Apartado 1350-3000
Heredia
COSTA RICA
mspi...@una.ac.cr
mspin...@gmail.com
Tel�fono: (506) 2277-3598
Fax: (506) 2237-7036
qplot(1:10, 1:10) +
scale_y_continuous(breaks=c(seq(2,10,by=2), 3.14)) +
geom_hline(aes(yintercept=y), data=data.frame(y=3.14), colour="blue")
HTH,
baptiste
On Sat, Sep 4, 2010 at 3:00 PM, Manuel Spínola <mspin...@gmail.com> wrote:
> Thank you very much Baptiste,
>
> I would like to recreate the attached plot. My problem is that I don't know
> how to specify the "7.81" in ggplot2.
> Best,
>
> Manuel
>
>
> On 04/09/2010 06:20 a.m., baptiste auguie wrote:
>>
>> library(ggplot2)
>> print(qplot(1,1), vp=viewport(height=0.8))
>> grid.text(0.5, unit(1,"npc") - unit(1,"line"), label="I'm (slightly)
>> out of here!")
>
>
> --
> Manuel Spínola, Ph.D.
> Instituto Internacional en Conservación y Manejo de Vida Silvestre
> Universidad Nacional
> Apartado 1350-3000
> Heredia
> COSTA RICA
> mspi...@una.ac.cr
> mspin...@gmail.com
> Teléfono: (506) 2277-3598
> Fax: (506) 2237-7036
>
>