[R] multiple series on same graph
Sven Garbade
garbade at psy.uni-muenchen.de
Wed Jan 30 10:26:24 CET 2002
Collin Carbno wrote:
>
> I'm trying to duplicate some graphs from powerpoint in R package. One
> of things I'm having trouble with is I don't understand how to use the
> points command to create different sets of points with different color
> and marking attributes, and a legend on the graph. Where should I look?
> I can't seem to find an example of two different sets of data on the
> same graph.
You can use points() or lines() to add points or lines to an existing
plot. See the help pages, there are a lot of examples on how to use
these functions. Use legend() to add a legend to a plot (and there are
also a lot of examples on how to use legend()). But you can also build
your legend with text(), polygon(), lines() etc if you prefer a flexible
style. See (for example)
http://cran.r-project.org/doc/contrib/rpsych.pdf on how to build a
legend with text(), polygon() etc.
By, Sven
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
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 at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
More information about the R-help
mailing list