2017年6月19日月曜日

2017JUN19 S&P 500 forecast


> as.xts(forecast(auto.arima(UC),h=10)$mean[1:10],as.Date(as.yearmon(seq(mondate(index(last(UC)))+1,by=1,length.out=10))))[(3-month(index(last(UC))) %% 3) + c(1,4,7)]
               [,1]
2017-07-01 1059.379
2017-10-01 1048.111
2018-01-01 1039.441
> as.xts(forecast(auto.arima(PA),h=10)$mean[1:10],as.Date(as.yearmon(seq(mondate(index(last(PA)))+1,by=1,length.out=10))))[(3-month(index(last(UC))) %% 3) + c(1,4,7)]
               [,1]
2017-07-01 146412.5
2017-10-01 146817.7
2018-01-01 147213.0

> my_sp5(last(GDP) * 1.05**(2/4),146412.5,1059)
[1] "m_m params! apply.quarter - UC w/ nominal GDP"
               GDP
2017-07-01 2471.38
> my_sp5(last(GDP) * 1.05**(3/4),146817.7,1048)
[1] "m_m params! apply.quarter - UC w/ nominal GDP"
                GDP
2017-10-01 2567.719
> my_sp5(last(GDP) * 1.05**(4/4),147213.0,1039)
[1] "m_m params! apply.quarter - UC w/ nominal GDP"
                GDP
2018-01-01 2661.749
> forecast(auto.arima(UC),h=10)$mean[1:10]
 [1] 1063.840 1059.379 1055.291 1051.545 1048.111 1044.965 1042.082 1039.441 1037.020 1034.801
>

0 件のコメント: