[R] plotting with a symbol on every nth point

R. Michael Weylandt michael.weylandt at gmail.com
Fri Oct 21 23:21:34 CEST 2011


Try something like this:

plot(x,type="o", pch = c(5,rep(NA,9)))

for, e.g., every 10th point.

Michael Weylandt

On Fri, Oct 21, 2011 at 5:18 PM, zugi young <zugi.young at gmail.com> wrote:
> Hi,
>
> I would like to produce a plot with a symbol on every nth point in a time
> series data, like the one in the following:
>
> http://www.phon.ucl.ac.uk/home/yi/ProsodyPro/EnglishFocus.png
>
> x <- seq(-100,1000,25)
> plot(x,type="l")
>
> Could someone help me out with the above example?
>
> Thanks....
>
>        [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



More information about the R-help mailing list