If I understand your question:
x <- rnorm(100)
plot(x)
legend("topright", capture.output(t(t(summary(x)))))
On 16/01/2008, Tom Snowden <tom.snowden at gmail.com>
wrote:>
> Hi,
>
> I am currently in the process of translating a large script from S-Plus
over
> to R. It's going well so far and all the high level stuff is working
fine,
> but as they say 'the devil is in the details' and my low level
stuff is
> struggling. Specifically, I have enountered a problem translating from
key()
> to legend(); in splus I was able to create a tables of statistics (AUCs and
> averages that I had calculated earlier in the script) that lined up with
the
> key using bits of script as simple as:
>
> key( text=list(temp.cd),
> text=list(temp.a),
> text=list(temp.b),
> text=list(temp.c),
> text=list(temp.d),
> text=list(temp.lab),
> lines=list(type=c("n", rep("o",
length(temp.cd))), col=temp.COL,
> pch=temp.PCH),
> border=F, corner=c(1, 1), align=T, cex=0.9)
>
> It is not obvious to me how I would achieve something similar in R and any
> help would be greatly appreciated.
>
> Tom
> --
> View this message in context:
http://www.nabble.com/Using-a-data-frame-to-create-a-legend-tp14880656p14880656.html
> Sent from the R help mailing list archive at Nabble.com.
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
--
Henrique Dallazuanna
Curitiba-Paran?-Brasil
25? 25' 40" S 49? 16' 22" O