简体   繁体   English

R中具有10分钟间隔的时间序列

[英]Time Series with 10min interval in R

I would like to create a time series with the function ts() but with 10 minutes interval data. 我想使用函数ts()创建一个具有10分钟间隔数据的时间序列。 My data is as follow: 我的数据如下:

01/10/2018 00:10    32
01/10/2018 00:20    30
01/10/2018 00:20    30
01/10/2018 00:30    31
01/10/2018 00:40    30

It starts at 01/10/2018 00:00 and goes to 31/05/2019 23:50 and it has 34849 rows of data. 它开始于01/10/2018 00:00到31/05/2019 23:50并且具有34849行数据。 I have seen questions similar to this here but I couldn't achieve the result with it's solutions... I tried this: 我在这里看到了与此类似的问题,但是我无法通过其解决方案实现结果……我尝试了以下操作:

oilT = ts(wtg01, start = c(2018,10), end = c(2019,5), deltat = 24*60/10)

Thanks in advance 提前致谢

The ts class is not designed for this type of data. ts类不适用于此类数据。 Try using the tsibble package instead which allows for much more general kinds of time indexed data. 尝试使用tsibble包代替,它允许使用更通用的时间索引数据。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM