[R] analog to the matlab buffer function?
Martin Ivanov
tramni at abv.bg
Thu Nov 30 23:30:46 CET 2006
Hello!
I am new to R. I could not find a function analogous to matlab's function buffer, which is used in signal processing. Is there such a function in R?
What I need to do is as follows. If I apply the function to the vector c(1:5) for example with a window length 3 and overlapping 2, I need to get a matrix like this:
1 2 3
2 3 4
3 4 5
In matlab this is achieved with the function buffer. Is there ananalogous R function?
Thank you very much in advance.
Regards,
Martin
More information about the R-help
mailing list