简体   繁体   English

我需要将时间戳“ 1/1/2018 0:00”转换为时间序列分析。 是否有代码可以使时间与该功能相关?

[英]I need to convert my timestamp of “1/1/2018 0:00” for my time series analysis. Is there a code to keep the time relevant in this function?

My goal is to highlight anomalies and trends seasonally in water quality data so I am trying to determine how I can convert and format the time stamps correctly. 我的目标是突出显示水质数据的季节性异常和趋势,因此我试图确定如何正确转换和格式化时间戳。

I am reading in from a csv. 我正在从csv阅读。 I have tried as.Date but that doesn't keep the time stamp and the time of day is relevant to my analyses. 我已经尝试过as.Date但这并不保留时间戳,并且一天中的时间与我的分析有关。

您还可以从timeDate包中使用as.timeDate(“ 2019-07-02 13:33:12”)。

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

相关问题 我想将 tbl_df 转换为 ts 进行时间序列分析。 我已经完成了,但丢失了我的 (Month) 列,这是我数据中的日期 - I want to convert tbl_df to ts for time series analysis. I have done it but lost my (Month) column which is date in my data 如何在 R 中将我的时间“箱”转换为连续的时间序列分析? - How do I convert my time “bins” to continous for a time series analysis in R? 我需要将一列日期转换为时间序列 - I need to convert a column of dates into a time series 我的数据没有转换为 R 中的时间序列 - My data does not convert to time series in R 将数据框转换为 xts 进行时间序列分析时我做错了什么? - What am I doing wrong in converting my data frame into xts for time series analysis? R中是否有可以将“时间”因子(00:00:00)转换为秒的函数 - Is there a function in R that can convert a "time" factor (00:00:00) into seconds 如何使用我自己的 function 从时间序列的 POSIXct 元素中提取日期和时间? - How can I extract date and time from a POSIXct element of a time series using my own function? 即使将数据集转换为ts文件进行时间序列分析后,为什么仍会收到此错误消息? - Why am I getting this error message even after transforming my data set into a ts file for time series analysis? 协变量的时间序列分析 - time series analysis with covariates 小时间序列分析 - small Time Series Analysis
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM