How to plot legend to the margin area of the graph?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

How to plot legend to the margin area of the graph?

Vincent Deng
Dear R-helpers,


When plotting a graph, what command should I use to mark legend to the
margin area of that graph?

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Reply | Threaded
Open this post in threaded view
|

Re: How to plot legend to the margin area of the graph?

Uwe Ligges
Vincent Deng wrote:

> Dear R-helpers,
>
>
> When plotting a graph, what command should I use to mark legend to the
> margin area of that graph?

Example:

plot(1:10)
par(xpd=TRUE)
legend(8,11.5,"Hello World")

Uwe Ligges


> ______________________________________________
> [hidden email] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html