[R] Daily Time Series, patterns.

mekbatub mekbatub at gmail.com
Mon Dec 3 14:14:03 CET 2012


Hi Arun, thanks again, I think we are close.
The way You gave me looks good, but I sill have one problem, look at this:

Lets say, we have data like this:

>head(dat3)

      Date       quantity
2012-03-05 65.16
2012-03-06 70.67
2012-03-08 63.66
2012-03-09 70.05
2012-03-12 61.59
2012-03-13 58.98

Then we have:
>z <- zooreg(dat3[,2], frequency = 5)
>z
1(1)     1(2)     1(3)     1(4)     1(5)     2(1)     
65.16  70.67  63.66  70.05  61.59   58.98

This is for dates:
1(1)               1(2)                1(3)               1(4)             
1(5)                2(1)     
2012-03-05 2012-03-06 2012-03-08 2012-03-09 2012-03-12 2012-03-13

Since there was no releases in 2012-03-07 (warehouse was closed)

We should have:
1(1)     1(2)     *1(4)     1(5)     1(1)     2(2) *    
65.16  70.67  63.66  70.05  61.59   58.98

So I can’t in that case use “frequency=5”. I am trying to figure out how to
assign correctly number of the week day to quantity.

I am wondering if my way of thinking is correct, maybe I should fill out
those missing values like You suggest me last time, but the problem is there
are not missing values really, for ex. if the warehouse was closed, there
was not supposed to be releases that day so there is nothing to fill out
really. 
I am wondering is it at all possible to do this in R like I am trying to do
– without data continuity.

What You think about that?



--
View this message in context: http://r.789695.n4.nabble.com/Daily-Time-Series-patterns-tp4651569p4651836.html
Sent from the R help mailing list archive at Nabble.com.




More information about the R-help mailing list