Re: R-beta: legend

Peter Dalgaard BSA (p.dalgaard@biostat.ku.dk)
20 Feb 1998 17:57:47 +0100


To: "Jay King" <jking@metisrv0.man-env.com>
Subject: Re: R-beta: legend
From: Peter Dalgaard BSA <p.dalgaard@biostat.ku.dk>
Date: 20 Feb 1998 17:57:47 +0100
In-Reply-To: "Jay King"'s message of Fri, 20 Feb 1998 10:48:00 +0000

"Jay King" <jking@metisrv0.man-env.com> writes:

> 
> Does the "legend" command work in the windows version of R? Here is 
> the command that I'm using:
> 
> legend(1,1,legend=c("G1","G2","G3","G4","G5","G6"),pch=array(1:6,dim=c
> (1,6)))
> 
> When I use this on my existing graph in a window I get a solid black 
> box at the lower left. If I use this with the postscript driver my 
> output file has neither a legend nor the black box.

You're not telling us what was on the plot in the first place, in
particular not the x- and y-extents. I don't recall observing anything
peculiar with the Windows version in that respect, but the plotting
routines may have some idiosyncracies when you try to plot things that
don't fit within the plotting frame.

First see if this works:

plot(1:6)
legend(1,6,legend=c("G1","G2","G3","G4","G5","G6"),pch=1:6)


-- 
   O__  ---- Peter Dalgaard             Blegdamsvej 3  
  c/ /'_ --- Dept. of Biostatistics     2200 Cph. N   
 (*) \(*) -- University of Copenhagen   Denmark      Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard@biostat.ku.dk)             FAX: (+45) 35327907

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._