Converting zoo object into a weekly time series
问题 I am working on building a time series in R programming language. I m having a zoo object which is follows: I 'd like to convert this into a weekly time series data for analysis and typed in the following code tt2<-as.ts(zz,freq=365.25/7,start=decimal_date(ymd("2018-01-01"))) tt2[is.na(tt2)]<-0 However, I get the following output: Time Series: Start = 17538 End = 18532 Frequency = 0.142857142857143 While I'd like to see the output in line with something like this: Time Series: Start = c(2018