[R] Plotting series marked with a symbol on every nth data point, preferably in ggplot...
Tribo Laboy
tribolaboy at gmail.com
Mon Feb 25 05:01:06 CET 2008
Hello!
I am working with signals and a plot of several signals on the same
axes can get quite messy. With lines that are very fractured,
distinction by only the linestyle is not very clear. If I add symbols
to the plot however, there are so many symbols, that they overplot and
the whole plot is unreadable once again. I am looking for advice on
how to make a plot with continuous lines and symbols appearing at
every nth point. An example of this problem and a solution in SAS can
be found here:
www2.sas.com/proceedings/sugi26/p072-26.pdf
The obvious solution would be to extract the n-th point from the
dataset and overplot as a new line with symbols, but this does not
change the legend, does it? How can I then have a line+symbol in the
legend represent my curve?
Now, ideally I would prefer a solution in ggplot, because of the ease
of plotting and changing the plot labels and other properties.
However, I remember, Hadley mentioned that he is still working on a
new version to have combined line+symbol plots, and probably he hasn't
finished that yet. So any advice is welcome.
Regards,
TL
PS. I did RTFM and I am not posting code, because at this time I
expect a general outline how to do it and what commands to lookup, not
code.
More information about the R-help
mailing list