Free Statistics

of Irreproducible Research!

Author's title

Author*The author of this computation has been verified*
R Software Modulerwasp_arimaforecasting.wasp
Title produced by softwareARIMA Forecasting
Date of computationSat, 11 Dec 2010 15:15:10 +0000
Cite this page as followsStatistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?v=date/2010/Dec/11/t1292080430a14xd0lhfr3tczp.htm/, Retrieved Fri, 03 May 2024 02:40:57 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=108201, Retrieved Fri, 03 May 2024 02:40:57 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact148
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-     [Univariate Data Series] [data set] [2008-12-01 19:54:57] [b98453cac15ba1066b407e146608df68]
- RMP   [ARIMA Backward Selection] [] [2009-11-27 14:53:14] [b98453cac15ba1066b407e146608df68]
-   PD    [ARIMA Backward Selection] [Workshop 9 - Arim...] [2009-12-03 16:04:59] [1646a2766cb8c4a6f9d3b2fffef409b3]
- RMPD      [Univariate Explorative Data Analysis] [Paper] [2009-12-31 11:25:34] [23722951c28e05bb35cc9a97084fe0d9]
- RMPD          [ARIMA Forecasting] [Paper Arima forecast] [2010-12-11 15:15:10] [81b44bf7e2a3251743773b0d7e91dd87] [Current]
Feedback Forum

Post a new message
Dataseries X:
172
150.6
163.3
153.7
152.9
135.5
148.5
148.4
133.6
194.1
208.6
197.3
164.4
148.1
152
144.1
155
124.5
153
146
138
190
192
192
147
133
163
150
129
131
145
137
138
168
176
188
139
143
150
154
137
129
128
140
143
151
177
184
151
134
164
126
131
125
127
143
143
160
190
182
138
136
152
127
151
130
119
153




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time1 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24

\begin{tabular}{lllllllll}
\hline
Summary of computational transaction \tabularnewline
Raw Input & view raw input (R code)  \tabularnewline
Raw Output & view raw output of R engine  \tabularnewline
Computing time & 1 seconds \tabularnewline
R Server & 'Sir Ronald Aylmer Fisher' @ 193.190.124.24 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=108201&T=0

[TABLE]
[ROW][C]Summary of computational 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]1 seconds[/C][/ROW]
[ROW][C]R Server[/C][C]'Sir Ronald Aylmer Fisher' @ 193.190.124.24[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=108201&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=108201&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 computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time1 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24







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[56])
44140-------
45143-------
46151-------
47177-------
48184-------
49151-------
50134-------
51164-------
52126-------
53131-------
54125-------
55127-------
56143-------
57143143121.2989164.70110.50.50.50.5
58160151129.2989172.70110.20810.7650.50.765
59190177155.2989198.70110.12020.93770.50.9989
60182184162.2989205.70110.42830.29390.50.9999
61138151129.2989172.70110.12020.00260.50.765
62136134112.2989155.70110.42830.35890.50.2081
63152164142.2989185.70110.13920.99430.50.9711
64127126104.2989147.70110.4640.00940.50.0623
65151131109.2989152.70110.03540.64110.50.1392
66130125103.2989146.70110.32580.00940.50.052
67119127105.2989148.70110.2350.39320.50.0742
68153143121.2989164.70110.18320.98490.50.5

\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[56]) \tabularnewline
44 & 140 & - & - & - & - & - & - & - \tabularnewline
45 & 143 & - & - & - & - & - & - & - \tabularnewline
46 & 151 & - & - & - & - & - & - & - \tabularnewline
47 & 177 & - & - & - & - & - & - & - \tabularnewline
48 & 184 & - & - & - & - & - & - & - \tabularnewline
49 & 151 & - & - & - & - & - & - & - \tabularnewline
50 & 134 & - & - & - & - & - & - & - \tabularnewline
51 & 164 & - & - & - & - & - & - & - \tabularnewline
52 & 126 & - & - & - & - & - & - & - \tabularnewline
53 & 131 & - & - & - & - & - & - & - \tabularnewline
54 & 125 & - & - & - & - & - & - & - \tabularnewline
55 & 127 & - & - & - & - & - & - & - \tabularnewline
56 & 143 & - & - & - & - & - & - & - \tabularnewline
57 & 143 & 143 & 121.2989 & 164.7011 & 0.5 & 0.5 & 0.5 & 0.5 \tabularnewline
58 & 160 & 151 & 129.2989 & 172.7011 & 0.2081 & 0.765 & 0.5 & 0.765 \tabularnewline
59 & 190 & 177 & 155.2989 & 198.7011 & 0.1202 & 0.9377 & 0.5 & 0.9989 \tabularnewline
60 & 182 & 184 & 162.2989 & 205.7011 & 0.4283 & 0.2939 & 0.5 & 0.9999 \tabularnewline
61 & 138 & 151 & 129.2989 & 172.7011 & 0.1202 & 0.0026 & 0.5 & 0.765 \tabularnewline
62 & 136 & 134 & 112.2989 & 155.7011 & 0.4283 & 0.3589 & 0.5 & 0.2081 \tabularnewline
63 & 152 & 164 & 142.2989 & 185.7011 & 0.1392 & 0.9943 & 0.5 & 0.9711 \tabularnewline
64 & 127 & 126 & 104.2989 & 147.7011 & 0.464 & 0.0094 & 0.5 & 0.0623 \tabularnewline
65 & 151 & 131 & 109.2989 & 152.7011 & 0.0354 & 0.6411 & 0.5 & 0.1392 \tabularnewline
66 & 130 & 125 & 103.2989 & 146.7011 & 0.3258 & 0.0094 & 0.5 & 0.052 \tabularnewline
67 & 119 & 127 & 105.2989 & 148.7011 & 0.235 & 0.3932 & 0.5 & 0.0742 \tabularnewline
68 & 153 & 143 & 121.2989 & 164.7011 & 0.1832 & 0.9849 & 0.5 & 0.5 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=108201&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[56])[/C][/ROW]
[ROW][C]44[/C][C]140[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]45[/C][C]143[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]46[/C][C]151[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]47[/C][C]177[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]48[/C][C]184[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]49[/C][C]151[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]50[/C][C]134[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]51[/C][C]164[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]52[/C][C]126[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]53[/C][C]131[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]54[/C][C]125[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]55[/C][C]127[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]56[/C][C]143[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]57[/C][C]143[/C][C]143[/C][C]121.2989[/C][C]164.7011[/C][C]0.5[/C][C]0.5[/C][C]0.5[/C][C]0.5[/C][/ROW]
[ROW][C]58[/C][C]160[/C][C]151[/C][C]129.2989[/C][C]172.7011[/C][C]0.2081[/C][C]0.765[/C][C]0.5[/C][C]0.765[/C][/ROW]
[ROW][C]59[/C][C]190[/C][C]177[/C][C]155.2989[/C][C]198.7011[/C][C]0.1202[/C][C]0.9377[/C][C]0.5[/C][C]0.9989[/C][/ROW]
[ROW][C]60[/C][C]182[/C][C]184[/C][C]162.2989[/C][C]205.7011[/C][C]0.4283[/C][C]0.2939[/C][C]0.5[/C][C]0.9999[/C][/ROW]
[ROW][C]61[/C][C]138[/C][C]151[/C][C]129.2989[/C][C]172.7011[/C][C]0.1202[/C][C]0.0026[/C][C]0.5[/C][C]0.765[/C][/ROW]
[ROW][C]62[/C][C]136[/C][C]134[/C][C]112.2989[/C][C]155.7011[/C][C]0.4283[/C][C]0.3589[/C][C]0.5[/C][C]0.2081[/C][/ROW]
[ROW][C]63[/C][C]152[/C][C]164[/C][C]142.2989[/C][C]185.7011[/C][C]0.1392[/C][C]0.9943[/C][C]0.5[/C][C]0.9711[/C][/ROW]
[ROW][C]64[/C][C]127[/C][C]126[/C][C]104.2989[/C][C]147.7011[/C][C]0.464[/C][C]0.0094[/C][C]0.5[/C][C]0.0623[/C][/ROW]
[ROW][C]65[/C][C]151[/C][C]131[/C][C]109.2989[/C][C]152.7011[/C][C]0.0354[/C][C]0.6411[/C][C]0.5[/C][C]0.1392[/C][/ROW]
[ROW][C]66[/C][C]130[/C][C]125[/C][C]103.2989[/C][C]146.7011[/C][C]0.3258[/C][C]0.0094[/C][C]0.5[/C][C]0.052[/C][/ROW]
[ROW][C]67[/C][C]119[/C][C]127[/C][C]105.2989[/C][C]148.7011[/C][C]0.235[/C][C]0.3932[/C][C]0.5[/C][C]0.0742[/C][/ROW]
[ROW][C]68[/C][C]153[/C][C]143[/C][C]121.2989[/C][C]164.7011[/C][C]0.1832[/C][C]0.9849[/C][C]0.5[/C][C]0.5[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=108201&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=108201&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[56])
44140-------
45143-------
46151-------
47177-------
48184-------
49151-------
50134-------
51164-------
52126-------
53131-------
54125-------
55127-------
56143-------
57143143121.2989164.70110.50.50.50.5
58160151129.2989172.70110.20810.7650.50.765
59190177155.2989198.70110.12020.93770.50.9989
60182184162.2989205.70110.42830.29390.50.9999
61138151129.2989172.70110.12020.00260.50.765
62136134112.2989155.70110.42830.35890.50.2081
63152164142.2989185.70110.13920.99430.50.9711
64127126104.2989147.70110.4640.00940.50.0623
65151131109.2989152.70110.03540.64110.50.1392
66130125103.2989146.70110.32580.00940.50.052
67119127105.2989148.70110.2350.39320.50.0742
68153143121.2989164.70110.18320.98490.50.5







Univariate ARIMA Extrapolation Forecast Performance
time% S.E.PEMAPESq.EMSERMSE
570.077400000
580.07330.05960.02988140.56.364
590.06260.07340.044316983.33339.1287
600.0602-0.01090.036463.57.9687
610.0733-0.08610.04616984.69.1978
620.08260.01490.0408471.16678.436
630.0675-0.07320.045414481.57149.0317
640.08790.00790.0408171.58.4558
650.08450.15270.053240010810.3923
660.08860.040.05192599.79.985
670.0872-0.0630.05296496.45459.8211
680.07740.06990.054310096.759.8362

\begin{tabular}{lllllllll}
\hline
Univariate ARIMA Extrapolation Forecast Performance \tabularnewline
time & % S.E. & PE & MAPE & Sq.E & MSE & RMSE \tabularnewline
57 & 0.0774 & 0 & 0 & 0 & 0 & 0 \tabularnewline
58 & 0.0733 & 0.0596 & 0.0298 & 81 & 40.5 & 6.364 \tabularnewline
59 & 0.0626 & 0.0734 & 0.0443 & 169 & 83.3333 & 9.1287 \tabularnewline
60 & 0.0602 & -0.0109 & 0.036 & 4 & 63.5 & 7.9687 \tabularnewline
61 & 0.0733 & -0.0861 & 0.046 & 169 & 84.6 & 9.1978 \tabularnewline
62 & 0.0826 & 0.0149 & 0.0408 & 4 & 71.1667 & 8.436 \tabularnewline
63 & 0.0675 & -0.0732 & 0.0454 & 144 & 81.5714 & 9.0317 \tabularnewline
64 & 0.0879 & 0.0079 & 0.0408 & 1 & 71.5 & 8.4558 \tabularnewline
65 & 0.0845 & 0.1527 & 0.0532 & 400 & 108 & 10.3923 \tabularnewline
66 & 0.0886 & 0.04 & 0.0519 & 25 & 99.7 & 9.985 \tabularnewline
67 & 0.0872 & -0.063 & 0.0529 & 64 & 96.4545 & 9.8211 \tabularnewline
68 & 0.0774 & 0.0699 & 0.0543 & 100 & 96.75 & 9.8362 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=108201&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]57[/C][C]0.0774[/C][C]0[/C][C]0[/C][C]0[/C][C]0[/C][C]0[/C][/ROW]
[ROW][C]58[/C][C]0.0733[/C][C]0.0596[/C][C]0.0298[/C][C]81[/C][C]40.5[/C][C]6.364[/C][/ROW]
[ROW][C]59[/C][C]0.0626[/C][C]0.0734[/C][C]0.0443[/C][C]169[/C][C]83.3333[/C][C]9.1287[/C][/ROW]
[ROW][C]60[/C][C]0.0602[/C][C]-0.0109[/C][C]0.036[/C][C]4[/C][C]63.5[/C][C]7.9687[/C][/ROW]
[ROW][C]61[/C][C]0.0733[/C][C]-0.0861[/C][C]0.046[/C][C]169[/C][C]84.6[/C][C]9.1978[/C][/ROW]
[ROW][C]62[/C][C]0.0826[/C][C]0.0149[/C][C]0.0408[/C][C]4[/C][C]71.1667[/C][C]8.436[/C][/ROW]
[ROW][C]63[/C][C]0.0675[/C][C]-0.0732[/C][C]0.0454[/C][C]144[/C][C]81.5714[/C][C]9.0317[/C][/ROW]
[ROW][C]64[/C][C]0.0879[/C][C]0.0079[/C][C]0.0408[/C][C]1[/C][C]71.5[/C][C]8.4558[/C][/ROW]
[ROW][C]65[/C][C]0.0845[/C][C]0.1527[/C][C]0.0532[/C][C]400[/C][C]108[/C][C]10.3923[/C][/ROW]
[ROW][C]66[/C][C]0.0886[/C][C]0.04[/C][C]0.0519[/C][C]25[/C][C]99.7[/C][C]9.985[/C][/ROW]
[ROW][C]67[/C][C]0.0872[/C][C]-0.063[/C][C]0.0529[/C][C]64[/C][C]96.4545[/C][C]9.8211[/C][/ROW]
[ROW][C]68[/C][C]0.0774[/C][C]0.0699[/C][C]0.0543[/C][C]100[/C][C]96.75[/C][C]9.8362[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=108201&T=2

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=108201&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
570.077400000
580.07330.05960.02988140.56.364
590.06260.07340.044316983.33339.1287
600.0602-0.01090.036463.57.9687
610.0733-0.08610.04616984.69.1978
620.08260.01490.0408471.16678.436
630.0675-0.07320.045414481.57149.0317
640.08790.00790.0408171.58.4558
650.08450.15270.053240010810.3923
660.08860.040.05192599.79.985
670.0872-0.0630.05296496.45459.8211
680.07740.06990.054310096.759.8362



Parameters (Session):
Parameters (R input):
par1 = 12 ; par2 = 1 ; par3 = 0 ; par4 = 1 ; par5 = 12 ; par6 = 0 ; par7 = 0 ; par8 = 0 ; par9 = 0 ; 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,par1))
(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)
}
if (par2 < 0) {
olb <- lb
lb <- ub
ub <- olb
}
(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.mape1 <- array(0, dim=fx)
perf.se <- array(0, dim=fx)
perf.mse <- array(0, dim=fx)
perf.mse1 <- 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.se[i] = (x[nx+i] - forecast$pred[i])^2
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[1] = abs(perf.pe[1])
perf.mse[1] = abs(perf.se[1])
for (i in 2:fx) {
perf.mape[i] = perf.mape[i-1] + abs(perf.pe[i])
perf.mape1[i] = perf.mape[i] / i
perf.mse[i] = perf.mse[i-1] + perf.se[i]
perf.mse1[i] = perf.mse[i] / i
}
perf.rmse = sqrt(perf.mse1)
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:par1] <- 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.mape1[i],4))
a<-table.element(a,round(perf.se[i],4))
a<-table.element(a,round(perf.mse1[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')