Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

stsm_detect_frequency

Detect frequency and dates from the data


Description

Detect frequency and dates from the data

Usage

stsm_detect_frequency(y, freq = NULL)

Arguments

y

Univariate time series of data values. May also be a 2 column data frame containing a date column.

freq

Initial setting for the frequency detection

Value

List giving the dates and frequency of the data

Examples

## Not run: 
#GDP Not seasonally adjusted
library(autostsm)
data("NA000334Q", package = "autostsm") #From FRED
NA000334Q = data.table(NA000334Q, keep.rownames = TRUE)
colnames(NA000334Q) = c("date", "y")
NA000334Q[, "date" := as.Date(date)]
NA000334Q[, "y" := as.numeric(y)]
NA000334Q = NA000334Q[date >= "1990-01-01", ]
freq = stsm_detect_frequency(y = NA000334Q)

## End(Not run)

autostsm

Automatic Structural Time Series Models

v1.3
GPL (>= 2)
Authors
Alex Hubbard
Initial release
2021-05-01

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.