ts_to_df {dateutils} | R Documentation |
ts() data to a dataframe
Description
Transform monthly or quarterly ts() data to a dataframe
Usage
ts_to_df(x, end_period = TRUE)
Arguments
x |
ts() format data which is either monthly or quarterly |
end_period |
T/F, for monthly or quarterly data, should dates be indexed to the end of the period? |
Value
Data in dataframe format
Examples
x <- ts(c(1,2,3,4), start=c(2020,1), end=c(2020,4), frequency=4)
ts_to_df(x)
[Package dateutils version 0.1.5 Index]