Consider the following scrap of code:

 > x<- ts(1:50,start=c(1,11),freq=12)
 > y <- aggregate(x,nfreq=4)
 > c(y)
 [1]   6  15  24  33  42  51  60  69  78  87  96 105 114 123 132 141
 > y
Error in rep.int("", start.pad) : invalid number of copies in rep.int()
 > tsp(y)
[1] 1.833333 5.583333 4.000000

So we can aggregate into quarters, but we cannot print it using 
print.ts  Even if print.ts cannot line the series into columns as it 
normally does for quarterly data, we would expect it to behave as it 
does when we  aggregate into thirds.

 > y3 <- aggregate(x,nfreq=3)
 > y3
Time Series:
Start = 1.83333333333333
End = 5.5
Frequency = 3
 [1]  10  26  42  58  74  90 106 122 138 154 170 186

And don't tell me that the aggregating a monthly series into quarters 
makes no sense!! (see response to Bug 9798).

Laimonis Kavalieris

______________________________________________
R-help@stat.math.ethz.ch 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.

Reply via email to