[R] How to add a data line (series) to a plot using add=TRUE
Mark Na
mtb954 at gmail.com
Tue Oct 28 20:49:14 CET 2008
Hello,
I'd like to use the add=TRUE parameter to add a second data line
(series) to an existing plot, but R is giving me an error (see below).
This code:
> rap<-plot(aspen_sort,ylim=c(1,10000),log="y")
...produces the plot to which I'd like to add the second line. But this
code:
> rap<-plot(pine_sort,add = TRUE)
...produces this error:
Warning messages:
1: In plot.window(...) : "add" is not a graphical parameter
2: In plot.xy(xy, type, ...) : "add" is not a graphical parameter
3: In axis(side = side, at = at, labels = labels, ...) :
"add" is not a graphical parameter
4: In axis(side = side, at = at, labels = labels, ...) :
"add" is not a graphical parameter
5: In box(...) : "add" is not a graphical parameter
6: In title(...) : "add" is not a graphical parameter
I have successfully used add=TRUE (in the same program!) with no errors,
so I reckon the problem must be related to my data structures, but I
can't see how.
Any ideas? Thanks!
Mark
More information about the R-help
mailing list