time-series

Time Series Forecasting with GARCH

两盒软妹~` 提交于 2020-08-03 08:16:38
问题 I am trying to forecast a time series object in R with GARCH(1,1) model. My goal is to hav 24 instances ahead forecast with the GARCH model. Although I am using a time series object while forecasting,I get the following error: Error in is.constant(y) : (list) object cannot be coerced to type 'double' Those are the commands that I am using: library(forecast) library(tseries) trainer1 <- ts(trainer, frequency=24) m1 <- garch(trainer1, order = c(1,1)) forecasts1 <- forecast(m1, h=24) And the

Time Series Forecasting with GARCH

╄→尐↘猪︶ㄣ 提交于 2020-08-03 08:16:09
问题 I am trying to forecast a time series object in R with GARCH(1,1) model. My goal is to hav 24 instances ahead forecast with the GARCH model. Although I am using a time series object while forecasting,I get the following error: Error in is.constant(y) : (list) object cannot be coerced to type 'double' Those are the commands that I am using: library(forecast) library(tseries) trainer1 <- ts(trainer, frequency=24) m1 <- garch(trainer1, order = c(1,1)) forecasts1 <- forecast(m1, h=24) And the

Create calendar table in SQL Server

会有一股神秘感。 提交于 2020-07-23 07:35:15
问题 I am using Microsoft SQL Server 2012 and I am creating the following table: Clinic_code Clinic_name D D_days_passed ------------------------------------------------------ A123 NAME1 2018-12-01 1 A124 NAME2 2018-12-01 1 A125 NAME3 2018-12-01 1 [...] A123 NAME1 2018-12-02 2 A124 NAME2 2018-12-02 2 A125 NAME3 2018-12-02 2 [...] A123 NAME1 2018-12-03 3 A124 NAME2 2018-12-03 3 A125 NAME3 2018-12-03 3 I adapted the code here from @JohnCappelletti, but I'm struggling to include the 'D_days_passed'

How to use configurable moving average for forecasting in R

房东的猫 提交于 2020-07-23 06:48:13
问题 I've 36 months of demand data dput(RawData) structure(list(ModelNo = c("a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a"), Month_Year = structure(c(1498867200, 1501545600, 1504224000, 1506816000, 1509494400, 1512086400, 1514764800, 1517443200, 1519862400, 1522540800, 1525132800, 1527811200, 1530403200, 1533081600, 1535760000, 1538352000, 1541030400, 1543622400,

How to use configurable moving average for forecasting in R

北城以北 提交于 2020-07-23 06:46:04
问题 I've 36 months of demand data dput(RawData) structure(list(ModelNo = c("a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a", "a"), Month_Year = structure(c(1498867200, 1501545600, 1504224000, 1506816000, 1509494400, 1512086400, 1514764800, 1517443200, 1519862400, 1522540800, 1525132800, 1527811200, 1530403200, 1533081600, 1535760000, 1538352000, 1541030400, 1543622400,