[R] How to setup the tsp attribute of a dataset
Samik Raychaudhuri
samikr at gmail.com
Fri Nov 20 23:53:46 CET 2009
Hello,
I am wondering how I should set up the tsp attribute (available through
attr(x, "tsp")) of a dataset x? Let's assume that x has 100 points, and
I want to set the frequency to 4.
I tried:
> attr(x,"tsp")<-c(1,100,4)
Error in attr(x, "tsp") <- c(1, 100, 4) :
invalid time series parameters specified
Is there any other way to set the frequency of the data?
Thanks.
-Samik
More information about the R-help
mailing list