Skip to content
Prev 359701 / 398502 Next

ts or xts with high-frequency data within a year

Bill, Josh, and Bert,

Thanks for your responses. I still can't quite get this when I use actual
dates. Here's an example of what is going wrong:

X=as.data.frame(1:6000)
X[2]=seq.POSIXt(ISOdate(2015,11,1),by='hour',length.out=6000)
X[3]=sample(100,size=6000,replace=T)

Y=xts(X[,3],order.by=X[,2])
decompose(Y)

Z=ts(X[,2],frequency=24*365)
plot(decompose(Z))

When I specify an actual date/time (rather than just a number as Bill
posited), it does not like anything short of a year. This seems like I'm
overlooking something obvious, but I can't get this for the life of me...

Thanks for your time,
r
On Wed, Mar 30, 2016 at 1:03 PM, William Dunlap <wdunlap at tibco.com> wrote: