Free Statistics

of Irreproducible Research!

Author's title

Author*Unverified author*
R Software Modulerwasp_arimaforecasting.wasp
Title produced by softwareARIMA Forecasting
Date of computationThu, 06 Dec 2007 13:14:40 -0700
Cite this page as followsStatistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?v=date/2007/Dec/06/t1196971314h5wzrbgaaipv7ag.htm/, Retrieved Fri, 03 May 2024 13:01:46 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=2710, Retrieved Fri, 03 May 2024 13:01:46 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact160
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-       [ARIMA Forecasting] [Q1] [2007-12-06 20:14:40] [2127dfc39c0d0690439ab654f5655d7e] [Current]
Feedback Forum

Post a new message
Dataseries X:
7,4
7,2
7
6,6
6,4
6,4
6,8
7,3
7
7
6,7
6,7
6,3
6,2
6
6,3
6,2
6,1
6,2
6,6
6,6
7,8
7,4
7,4
7,5
7,4
7,4
7
6,9
6,9
7,6
7,7
7,6
8,2
8
8,1
8,3
8,2
8,1
7,7
7,6
7,7
8,2
8,4
8,4
8,6
8,4
8,5
8,7
8,7
8,6
7,4
7,3
7,4
9
9,2
9,2
8,5
8,3
8,3
8,6
8,6
8,5
8,1
8,1
8
8,6
8,7
8,7
8,6
8,4
8,4
8,7
8,7
8,5
8,3
8,3
8,3
8,1
8,2
8,1
8,1
7,9
7,7
8,1
8
7,7
7,8
7,6
7,4
7,7
7,9
7,6




Summary of compuational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time7 seconds
R Server'Herman Ole Andreas Wold' @ 193.190.124.10:1001

\begin{tabular}{lllllllll}
\hline
Summary of compuational transaction \tabularnewline
Raw Input & view raw input (R code)  \tabularnewline
Raw Output & view raw output of R engine  \tabularnewline
Computing time & 7 seconds \tabularnewline
R Server & 'Herman Ole Andreas Wold' @ 193.190.124.10:1001 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=2710&T=0

[TABLE]
[ROW][C]Summary of compuational transaction[/C][/ROW]
[ROW][C]Raw Input[/C][C]view raw input (R code) [/C][/ROW]
[ROW][C]Raw Output[/C][C]view raw output of R engine [/C][/ROW]
[ROW][C]Computing time[/C][C]7 seconds[/C][/ROW]
[ROW][C]R Server[/C][C]'Herman Ole Andreas Wold' @ 193.190.124.10:1001[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=2710&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=2710&T=0

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Summary of compuational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time7 seconds
R Server'Herman Ole Andreas Wold' @ 193.190.124.10:1001







Univariate ARIMA Extrapolation Forecast
timeY[t]F[t]95% LB95% UBp-value(H0: Y[t] = F[t])P(F[t]>Y[t-1])P(F[t]>Y[t-s])P(F[t]>Y[93])
818.1-------
828.1-------
837.9-------
847.7-------
858.1-------
868-------
877.7-------
887.8-------
897.6-------
907.4-------
917.7-------
927.9-------
937.6-------
94NA7.53557.03158.0757NA0.40750.02030.4075
95NA7.37376.68978.1275NANA0.08560.2781
96NA7.38756.56978.307NANA0.25260.3253
97NA7.67436.77938.6874NANA0.20510.5571
98NA7.66016.72948.7196NANA0.26480.5443
99NA7.48556.53778.5706NANA0.34920.418
100NA7.37966.39078.5216NANA0.23530.3526
101NA7.27336.24418.4721NANA0.29660.2966
102NA7.21726.14678.4741NANA0.38780.2753
103NA7.42036.27848.77NANA0.34230.3971
104NA7.5156.32038.9355NANA0.29760.4533
105NA7.35446.14898.7963NANA0.36920.3692

\begin{tabular}{lllllllll}
\hline
Univariate ARIMA Extrapolation Forecast \tabularnewline
time & Y[t] & F[t] & 95% LB & 95% UB & p-value(H0: Y[t] = F[t]) & P(F[t]>Y[t-1]) & P(F[t]>Y[t-s]) & P(F[t]>Y[93]) \tabularnewline
81 & 8.1 & - & - & - & - & - & - & - \tabularnewline
82 & 8.1 & - & - & - & - & - & - & - \tabularnewline
83 & 7.9 & - & - & - & - & - & - & - \tabularnewline
84 & 7.7 & - & - & - & - & - & - & - \tabularnewline
85 & 8.1 & - & - & - & - & - & - & - \tabularnewline
86 & 8 & - & - & - & - & - & - & - \tabularnewline
87 & 7.7 & - & - & - & - & - & - & - \tabularnewline
88 & 7.8 & - & - & - & - & - & - & - \tabularnewline
89 & 7.6 & - & - & - & - & - & - & - \tabularnewline
90 & 7.4 & - & - & - & - & - & - & - \tabularnewline
91 & 7.7 & - & - & - & - & - & - & - \tabularnewline
92 & 7.9 & - & - & - & - & - & - & - \tabularnewline
93 & 7.6 & - & - & - & - & - & - & - \tabularnewline
94 & NA & 7.5355 & 7.0315 & 8.0757 & NA & 0.4075 & 0.0203 & 0.4075 \tabularnewline
95 & NA & 7.3737 & 6.6897 & 8.1275 & NA & NA & 0.0856 & 0.2781 \tabularnewline
96 & NA & 7.3875 & 6.5697 & 8.307 & NA & NA & 0.2526 & 0.3253 \tabularnewline
97 & NA & 7.6743 & 6.7793 & 8.6874 & NA & NA & 0.2051 & 0.5571 \tabularnewline
98 & NA & 7.6601 & 6.7294 & 8.7196 & NA & NA & 0.2648 & 0.5443 \tabularnewline
99 & NA & 7.4855 & 6.5377 & 8.5706 & NA & NA & 0.3492 & 0.418 \tabularnewline
100 & NA & 7.3796 & 6.3907 & 8.5216 & NA & NA & 0.2353 & 0.3526 \tabularnewline
101 & NA & 7.2733 & 6.2441 & 8.4721 & NA & NA & 0.2966 & 0.2966 \tabularnewline
102 & NA & 7.2172 & 6.1467 & 8.4741 & NA & NA & 0.3878 & 0.2753 \tabularnewline
103 & NA & 7.4203 & 6.2784 & 8.77 & NA & NA & 0.3423 & 0.3971 \tabularnewline
104 & NA & 7.515 & 6.3203 & 8.9355 & NA & NA & 0.2976 & 0.4533 \tabularnewline
105 & NA & 7.3544 & 6.1489 & 8.7963 & NA & NA & 0.3692 & 0.3692 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=2710&T=1

[TABLE]
[ROW][C]Univariate ARIMA Extrapolation Forecast[/C][/ROW]
[ROW][C]time[/C][C]Y[t][/C][C]F[t][/C][C]95% LB[/C][C]95% UB[/C][C]p-value(H0: Y[t] = F[t])[/C][C]P(F[t]>Y[t-1])[/C][C]P(F[t]>Y[t-s])[/C][C]P(F[t]>Y[93])[/C][/ROW]
[ROW][C]81[/C][C]8.1[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]82[/C][C]8.1[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]83[/C][C]7.9[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]84[/C][C]7.7[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]85[/C][C]8.1[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]86[/C][C]8[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]87[/C][C]7.7[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]88[/C][C]7.8[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]89[/C][C]7.6[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]90[/C][C]7.4[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]91[/C][C]7.7[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]92[/C][C]7.9[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]93[/C][C]7.6[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]94[/C][C]NA[/C][C]7.5355[/C][C]7.0315[/C][C]8.0757[/C][C]NA[/C][C]0.4075[/C][C]0.0203[/C][C]0.4075[/C][/ROW]
[ROW][C]95[/C][C]NA[/C][C]7.3737[/C][C]6.6897[/C][C]8.1275[/C][C]NA[/C][C]NA[/C][C]0.0856[/C][C]0.2781[/C][/ROW]
[ROW][C]96[/C][C]NA[/C][C]7.3875[/C][C]6.5697[/C][C]8.307[/C][C]NA[/C][C]NA[/C][C]0.2526[/C][C]0.3253[/C][/ROW]
[ROW][C]97[/C][C]NA[/C][C]7.6743[/C][C]6.7793[/C][C]8.6874[/C][C]NA[/C][C]NA[/C][C]0.2051[/C][C]0.5571[/C][/ROW]
[ROW][C]98[/C][C]NA[/C][C]7.6601[/C][C]6.7294[/C][C]8.7196[/C][C]NA[/C][C]NA[/C][C]0.2648[/C][C]0.5443[/C][/ROW]
[ROW][C]99[/C][C]NA[/C][C]7.4855[/C][C]6.5377[/C][C]8.5706[/C][C]NA[/C][C]NA[/C][C]0.3492[/C][C]0.418[/C][/ROW]
[ROW][C]100[/C][C]NA[/C][C]7.3796[/C][C]6.3907[/C][C]8.5216[/C][C]NA[/C][C]NA[/C][C]0.2353[/C][C]0.3526[/C][/ROW]
[ROW][C]101[/C][C]NA[/C][C]7.2733[/C][C]6.2441[/C][C]8.4721[/C][C]NA[/C][C]NA[/C][C]0.2966[/C][C]0.2966[/C][/ROW]
[ROW][C]102[/C][C]NA[/C][C]7.2172[/C][C]6.1467[/C][C]8.4741[/C][C]NA[/C][C]NA[/C][C]0.3878[/C][C]0.2753[/C][/ROW]
[ROW][C]103[/C][C]NA[/C][C]7.4203[/C][C]6.2784[/C][C]8.77[/C][C]NA[/C][C]NA[/C][C]0.3423[/C][C]0.3971[/C][/ROW]
[ROW][C]104[/C][C]NA[/C][C]7.515[/C][C]6.3203[/C][C]8.9355[/C][C]NA[/C][C]NA[/C][C]0.2976[/C][C]0.4533[/C][/ROW]
[ROW][C]105[/C][C]NA[/C][C]7.3544[/C][C]6.1489[/C][C]8.7963[/C][C]NA[/C][C]NA[/C][C]0.3692[/C][C]0.3692[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=2710&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=2710&T=1

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Univariate ARIMA Extrapolation Forecast
timeY[t]F[t]95% LB95% UBp-value(H0: Y[t] = F[t])P(F[t]>Y[t-1])P(F[t]>Y[t-s])P(F[t]>Y[93])
818.1-------
828.1-------
837.9-------
847.7-------
858.1-------
868-------
877.7-------
887.8-------
897.6-------
907.4-------
917.7-------
927.9-------
937.6-------
94NA7.53557.03158.0757NA0.40750.02030.4075
95NA7.37376.68978.1275NANA0.08560.2781
96NA7.38756.56978.307NANA0.25260.3253
97NA7.67436.77938.6874NANA0.20510.5571
98NA7.66016.72948.7196NANA0.26480.5443
99NA7.48556.53778.5706NANA0.34920.418
100NA7.37966.39078.5216NANA0.23530.3526
101NA7.27336.24418.4721NANA0.29660.2966
102NA7.21726.14678.4741NANA0.38780.2753
103NA7.42036.27848.77NANA0.34230.3971
104NA7.5156.32038.9355NANA0.29760.4533
105NA7.35446.14898.7963NANA0.36920.3692







Univariate ARIMA Extrapolation Forecast Performance
time% S.E.PEMAPESq.EMSERMSE
940.0366NANANANANA
950.0522NANANANANA
960.0635NANANANANA
970.0674NANANANANA
980.0706NANANANANA
990.074NANANANANA
1000.0789NANANANANA
1010.0841NANANANANA
1020.0889NANANANANA
1030.0928NANANANANA
1040.0964NANANANANA
1050.1NANANANANA

\begin{tabular}{lllllllll}
\hline
Univariate ARIMA Extrapolation Forecast Performance \tabularnewline
time & % S.E. & PE & MAPE & Sq.E & MSE & RMSE \tabularnewline
94 & 0.0366 & NA & NA & NA & NA & NA \tabularnewline
95 & 0.0522 & NA & NA & NA & NA & NA \tabularnewline
96 & 0.0635 & NA & NA & NA & NA & NA \tabularnewline
97 & 0.0674 & NA & NA & NA & NA & NA \tabularnewline
98 & 0.0706 & NA & NA & NA & NA & NA \tabularnewline
99 & 0.074 & NA & NA & NA & NA & NA \tabularnewline
100 & 0.0789 & NA & NA & NA & NA & NA \tabularnewline
101 & 0.0841 & NA & NA & NA & NA & NA \tabularnewline
102 & 0.0889 & NA & NA & NA & NA & NA \tabularnewline
103 & 0.0928 & NA & NA & NA & NA & NA \tabularnewline
104 & 0.0964 & NA & NA & NA & NA & NA \tabularnewline
105 & 0.1 & NA & NA & NA & NA & NA \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=2710&T=2

[TABLE]
[ROW][C]Univariate ARIMA Extrapolation Forecast Performance[/C][/ROW]
[ROW][C]time[/C][C]% S.E.[/C][C]PE[/C][C]MAPE[/C][C]Sq.E[/C][C]MSE[/C][C]RMSE[/C][/ROW]
[ROW][C]94[/C][C]0.0366[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[ROW][C]95[/C][C]0.0522[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[ROW][C]96[/C][C]0.0635[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[ROW][C]97[/C][C]0.0674[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[ROW][C]98[/C][C]0.0706[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[ROW][C]99[/C][C]0.074[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[ROW][C]100[/C][C]0.0789[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[ROW][C]101[/C][C]0.0841[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[ROW][C]102[/C][C]0.0889[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[ROW][C]103[/C][C]0.0928[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[ROW][C]104[/C][C]0.0964[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[ROW][C]105[/C][C]0.1[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=2710&T=2

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=2710&T=2

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Univariate ARIMA Extrapolation Forecast Performance
time% S.E.PEMAPESq.EMSERMSE
940.0366NANANANANA
950.0522NANANANANA
960.0635NANANANANA
970.0674NANANANANA
980.0706NANANANANA
990.074NANANANANA
1000.0789NANANANANA
1010.0841NANANANANA
1020.0889NANANANANA
1030.0928NANANANANA
1040.0964NANANANANA
1050.1NANANANANA



Parameters (Session):
par1 = 0 ; par2 = 0.0 ; par3 = 1 ; par4 = 0 ; par5 = 12 ; par6 = 3 ; par7 = 1 ; par8 = 2 ; par9 = 1 ; par10 = FALSE ;
Parameters (R input):
par1 = 0 ; par2 = 0.0 ; par3 = 1 ; par4 = 0 ; par5 = 12 ; par6 = 3 ; par7 = 1 ; par8 = 2 ; par9 = 1 ; par10 = FALSE ;
R code (references can be found in the software module):
par1 <- as.numeric(par1) #cut off periods
par2 <- as.numeric(par2) #lambda
par3 <- as.numeric(par3) #degree of non-seasonal differencing
par4 <- as.numeric(par4) #degree of seasonal differencing
par5 <- as.numeric(par5) #seasonal period
par6 <- as.numeric(par6) #p
par7 <- as.numeric(par7) #q
par8 <- as.numeric(par8) #P
par9 <- as.numeric(par9) #Q
if (par10 == 'TRUE') par10 <- TRUE
if (par10 == 'FALSE') par10 <- FALSE
if (par2 == 0) x <- log(x)
if (par2 != 0) x <- x^par2
lx <- length(x)
first <- lx - 2*par1
nx <- lx - par1
nx1 <- nx + 1
fx <- lx - nx
if (fx < 1) {
fx <- par5
nx1 <- lx + fx - 1
first <- lx - 2*fx
}
first <- 1
if (fx < 3) fx <- round(lx/10,0)
(arima.out <- arima(x[1:nx], order=c(par6,par3,par7), seasonal=list(order=c(par8,par4,par9), period=par5), include.mean=par10, method='ML'))
(forecast <- predict(arima.out,fx))
(lb <- forecast$pred - 1.96 * forecast$se)
(ub <- forecast$pred + 1.96 * forecast$se)
if (par2 == 0) {
x <- exp(x)
forecast$pred <- exp(forecast$pred)
lb <- exp(lb)
ub <- exp(ub)
}
if (par2 != 0) {
x <- x^(1/par2)
forecast$pred <- forecast$pred^(1/par2)
lb <- lb^(1/par2)
ub <- ub^(1/par2)
}
(actandfor <- c(x[1:nx], forecast$pred))
(perc.se <- (ub-forecast$pred)/1.96/forecast$pred)
bitmap(file='test1.png')
opar <- par(mar=c(4,4,2,2),las=1)
ylim <- c( min(x[first:nx],lb), max(x[first:nx],ub))
plot(x,ylim=ylim,type='n',xlim=c(first,lx))
usr <- par('usr')
rect(usr[1],usr[3],nx+1,usr[4],border=NA,col='lemonchiffon')
rect(nx1,usr[3],usr[2],usr[4],border=NA,col='lavender')
abline(h= (-3:3)*2 , col ='gray', lty =3)
polygon( c(nx1:lx,lx:nx1), c(lb,rev(ub)), col = 'orange', lty=2,border=NA)
lines(nx1:lx, lb , lty=2)
lines(nx1:lx, ub , lty=2)
lines(x, lwd=2)
lines(nx1:lx, forecast$pred , lwd=2 , col ='white')
box()
par(opar)
dev.off()
prob.dec <- array(NA, dim=fx)
prob.sdec <- array(NA, dim=fx)
prob.ldec <- array(NA, dim=fx)
prob.pval <- array(NA, dim=fx)
perf.pe <- array(0, dim=fx)
perf.mape <- array(0, dim=fx)
perf.se <- array(0, dim=fx)
perf.mse <- array(0, dim=fx)
perf.rmse <- array(0, dim=fx)
for (i in 1:fx) {
locSD <- (ub[i] - forecast$pred[i]) / 1.96
perf.pe[i] = (x[nx+i] - forecast$pred[i]) / forecast$pred[i]
perf.mape[i] = perf.mape[i] + abs(perf.pe[i])
perf.se[i] = (x[nx+i] - forecast$pred[i])^2
perf.mse[i] = perf.mse[i] + perf.se[i]
prob.dec[i] = pnorm((x[nx+i-1] - forecast$pred[i]) / locSD)
prob.sdec[i] = pnorm((x[nx+i-par5] - forecast$pred[i]) / locSD)
prob.ldec[i] = pnorm((x[nx] - forecast$pred[i]) / locSD)
prob.pval[i] = pnorm(abs(x[nx+i] - forecast$pred[i]) / locSD)
}
perf.mape = perf.mape / fx
perf.mse = perf.mse / fx
perf.rmse = sqrt(perf.mse)
bitmap(file='test2.png')
plot(forecast$pred, pch=19, type='b',main='ARIMA Extrapolation Forecast', ylab='Forecast and 95% CI', xlab='time',ylim=c(min(lb),max(ub)))
dum <- forecast$pred
dum[1:12] <- x[(nx+1):lx]
lines(dum, lty=1)
lines(ub,lty=3)
lines(lb,lty=3)
dev.off()
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Univariate ARIMA Extrapolation Forecast',9,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'time',1,header=TRUE)
a<-table.element(a,'Y[t]',1,header=TRUE)
a<-table.element(a,'F[t]',1,header=TRUE)
a<-table.element(a,'95% LB',1,header=TRUE)
a<-table.element(a,'95% UB',1,header=TRUE)
a<-table.element(a,'p-value
(H0: Y[t] = F[t])',1,header=TRUE)
a<-table.element(a,'P(F[t]>Y[t-1])',1,header=TRUE)
a<-table.element(a,'P(F[t]>Y[t-s])',1,header=TRUE)
mylab <- paste('P(F[t]>Y[',nx,sep='')
mylab <- paste(mylab,'])',sep='')
a<-table.element(a,mylab,1,header=TRUE)
a<-table.row.end(a)
for (i in (nx-par5):nx) {
a<-table.row.start(a)
a<-table.element(a,i,header=TRUE)
a<-table.element(a,x[i])
a<-table.element(a,'-')
a<-table.element(a,'-')
a<-table.element(a,'-')
a<-table.element(a,'-')
a<-table.element(a,'-')
a<-table.element(a,'-')
a<-table.element(a,'-')
a<-table.row.end(a)
}
for (i in 1:fx) {
a<-table.row.start(a)
a<-table.element(a,nx+i,header=TRUE)
a<-table.element(a,round(x[nx+i],4))
a<-table.element(a,round(forecast$pred[i],4))
a<-table.element(a,round(lb[i],4))
a<-table.element(a,round(ub[i],4))
a<-table.element(a,round((1-prob.pval[i]),4))
a<-table.element(a,round((1-prob.dec[i]),4))
a<-table.element(a,round((1-prob.sdec[i]),4))
a<-table.element(a,round((1-prob.ldec[i]),4))
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Univariate ARIMA Extrapolation Forecast Performance',7,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'time',1,header=TRUE)
a<-table.element(a,'% S.E.',1,header=TRUE)
a<-table.element(a,'PE',1,header=TRUE)
a<-table.element(a,'MAPE',1,header=TRUE)
a<-table.element(a,'Sq.E',1,header=TRUE)
a<-table.element(a,'MSE',1,header=TRUE)
a<-table.element(a,'RMSE',1,header=TRUE)
a<-table.row.end(a)
for (i in 1:fx) {
a<-table.row.start(a)
a<-table.element(a,nx+i,header=TRUE)
a<-table.element(a,round(perc.se[i],4))
a<-table.element(a,round(perf.pe[i],4))
a<-table.element(a,round(perf.mape[i],4))
a<-table.element(a,round(perf.se[i],4))
a<-table.element(a,round(perf.mse[i],4))
a<-table.element(a,round(perf.rmse[i],4))
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable1.tab')