[R-SIG-Mac] "legend" command does nothing
Simon Urbanek
simon.urbanek at r-project.org
Sat Sep 18 18:39:11 CEST 2010
Adrian,
missing fonts have cropped up a few times - so far the most common cause were broken fonts - please check your Font Book for duplicate or broken fonts (most specifically Arial). Please let me know if that was the cause.
Thanks,
Simon
On Sep 18, 2010, at 7:35 AM, Adrian wrote:
> Hello,
>
> I am having problems adding legends to my plots. For example, the command
> at the bottom of this message produces no legend for me. The plot appears
> correctly, but the legend is completely absent. Am I doing something
> incorrectly in the syntax of the legend function?
>
> It is possible that this is related to a problem that I posted previously on
> this list: I do not see any text on any graphs unless I explicitly supply
> the "family="sans"" argument to any plotting function.
>
> Any advice is appreciated. Thank you,
> Adrian Down
>
> quartz()
>
> Y=cbind(loglamt,yp)
>
> matplot(x,Y,
>
> xlab="N(t)",ylab="log{N(t+1)/N(t)}",main=ttext,
>
> type=c("p","l","l","l","l"),pch=21,col=c("black","blue","green","red",
> "purple"),lty=1,lwd=2,family="sans")
>
> legend("topright",c("Data","DI model","Ricker","Theta Logistic","Allee"),pch
> =c(21,-1,-1,-1),
>
> col=c("black","blue","green","red","purple"),lty=c("blank","solid","solid",
> "solid","solid"),lwd=2,plot=TRUE)
>
> [[alternative HTML version deleted]]
>
> _______________________________________________
> R-SIG-Mac mailing list
> R-SIG-Mac at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/r-sig-mac
>
>
More information about the R-SIG-Mac
mailing list