[R] How to create a legend that automatically reads the values from two vectors?

jcano javier.cano at urjc.es
Thu Oct 22 12:53:13 CEST 2009


Hi JIm

Not exactly what I want, as I can't draw the lines corresponding to the
different curves in the plot as I can do in legend, but may be still of
help.

Thkx, Javier



Jim Lemon-2 wrote:
> 
> On 10/21/2009 01:30 AM, jcano wrote:
>> betav<-c(0.78,0.94,0.88,0.41,0.59,4.68)
>> etav<-c(235.6,59.5,31.2,8.7,3.2,1174)
>>    
> Hi Javier,
> Maybe not exactly what you want, but try:
> 
> addtable2plot(2,8,rbind(betav,etav),bty="o",
>   display.colnames=FALSE,display.rownames=TRUE)
> 
> using your own x and y coordinates, of course. addtable2plot is in the 
> plotrix package.
> 
> Jim
> 
> ______________________________________________
> 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.
> 
> 

-- 
View this message in context: http://www.nabble.com/How-to-create-a-legend-that-automatically-reads-the-values-from-two-vectors--tp25976164p26007936.html
Sent from the R help mailing list archive at Nabble.com.




More information about the R-help mailing list