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 computationWed, 29 Dec 2010 11:18:38 +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/29/t1293621440w00czrj73izhq6a.htm/, Retrieved Fri, 03 May 2024 11:31:00 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=116709, Retrieved Fri, 03 May 2024 11:31:00 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact123
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-     [ARIMA Forecasting] [ARIMA Forecasting...] [2010-12-19 16:08:12] [fd57ceeb2f72ef497e1390930b11fced]
-   PD  [ARIMA Forecasting] [paper] [2010-12-28 15:40:56] [83d13bd1a1b3e64dad996f4022b3c29f]
-           [ARIMA Forecasting] [arima forecasting...] [2010-12-29 11:18:38] [36a5183bc8f6439b2481209b0fbe6bda] [Current]
Feedback Forum

Post a new message
Dataseries X:
595.130
526.883
562.254
545.427
522.084
483.414
528.797
532.749
511.380
472.941
516.118
502.940
476.118
432.418
475.525
453.638
431.417
390.934
436.414
418.451
399.528
367.749
423.433
420.450
415.906
392.949
453.203
455.926
451.879
434.996
498.811
505.940
517.395
508.456
585.132
587.971
584.027
557.196
613.433
600.049
588.993
559.271
622.580
616.645
603.243
557.949
608.882
582.930
570.492
542.907
598.067
568.717
551.773
514.465
569.055
528.897
515.229
481.141
535.612
498.547
478.587
445.911
503.412
469.797
458.365
436.761
502.205
481.627
473.698
457.200
521.671
513.354
515.369
505.652
575.676
555.865
559.504
540.994
605.635
600.315
588.224
569.861
625.950
601.554
587.760
573.307
621.764
570.214
547.034
511.873
553.870
517.058
505.702
479.060
526.638
508.060
532.394
532.115
587.896
565.710
572.708
544.417
597.160




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time2 seconds
R Server'RServer@AstonUniversity' @ vre.aston.ac.uk

\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 & 2 seconds \tabularnewline
R Server & 'RServer@AstonUniversity' @ vre.aston.ac.uk \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=116709&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]2 seconds[/C][/ROW]
[ROW][C]R Server[/C][C]'RServer@AstonUniversity' @ vre.aston.ac.uk[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=116709&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=116709&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 time2 seconds
R Server'RServer@AstonUniversity' @ vre.aston.ac.uk







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[91])
87621.764-------
88570.214-------
89547.034-------
90511.873-------
91553.87-------
92517.058504.4447488.0092520.88020.0663000
93505.702472.953442.3768503.52920.01790.002300
94479.06432.4026385.9305478.87460.02450.0014e-040
95526.638465.8805401.7408530.02020.03170.34360.00360.0036
96508.06409.1033320.3568497.84980.01440.00470.00867e-04
97532.394370.2818254.0564486.50730.00310.01010.01120.001
98532.115322.4021176.1976468.60660.00250.00240.01790.001
99587.896348.5507170.0836527.01790.00430.02190.02520.0121
100565.71284.444267.1777501.71080.00560.00310.02180.0075
101572.708238.2935-21.2962497.88310.00580.00670.01320.0086
102544.417183.0845-121.9315488.10050.01010.00610.01250.0086
103597.16201.9038-151.3701555.17770.01420.02870.01610.0254

\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[91]) \tabularnewline
87 & 621.764 & - & - & - & - & - & - & - \tabularnewline
88 & 570.214 & - & - & - & - & - & - & - \tabularnewline
89 & 547.034 & - & - & - & - & - & - & - \tabularnewline
90 & 511.873 & - & - & - & - & - & - & - \tabularnewline
91 & 553.87 & - & - & - & - & - & - & - \tabularnewline
92 & 517.058 & 504.4447 & 488.0092 & 520.8802 & 0.0663 & 0 & 0 & 0 \tabularnewline
93 & 505.702 & 472.953 & 442.3768 & 503.5292 & 0.0179 & 0.0023 & 0 & 0 \tabularnewline
94 & 479.06 & 432.4026 & 385.9305 & 478.8746 & 0.0245 & 0.001 & 4e-04 & 0 \tabularnewline
95 & 526.638 & 465.8805 & 401.7408 & 530.0202 & 0.0317 & 0.3436 & 0.0036 & 0.0036 \tabularnewline
96 & 508.06 & 409.1033 & 320.3568 & 497.8498 & 0.0144 & 0.0047 & 0.0086 & 7e-04 \tabularnewline
97 & 532.394 & 370.2818 & 254.0564 & 486.5073 & 0.0031 & 0.0101 & 0.0112 & 0.001 \tabularnewline
98 & 532.115 & 322.4021 & 176.1976 & 468.6066 & 0.0025 & 0.0024 & 0.0179 & 0.001 \tabularnewline
99 & 587.896 & 348.5507 & 170.0836 & 527.0179 & 0.0043 & 0.0219 & 0.0252 & 0.0121 \tabularnewline
100 & 565.71 & 284.4442 & 67.1777 & 501.7108 & 0.0056 & 0.0031 & 0.0218 & 0.0075 \tabularnewline
101 & 572.708 & 238.2935 & -21.2962 & 497.8831 & 0.0058 & 0.0067 & 0.0132 & 0.0086 \tabularnewline
102 & 544.417 & 183.0845 & -121.9315 & 488.1005 & 0.0101 & 0.0061 & 0.0125 & 0.0086 \tabularnewline
103 & 597.16 & 201.9038 & -151.3701 & 555.1777 & 0.0142 & 0.0287 & 0.0161 & 0.0254 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=116709&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[91])[/C][/ROW]
[ROW][C]87[/C][C]621.764[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]88[/C][C]570.214[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]89[/C][C]547.034[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]90[/C][C]511.873[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]91[/C][C]553.87[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]92[/C][C]517.058[/C][C]504.4447[/C][C]488.0092[/C][C]520.8802[/C][C]0.0663[/C][C]0[/C][C]0[/C][C]0[/C][/ROW]
[ROW][C]93[/C][C]505.702[/C][C]472.953[/C][C]442.3768[/C][C]503.5292[/C][C]0.0179[/C][C]0.0023[/C][C]0[/C][C]0[/C][/ROW]
[ROW][C]94[/C][C]479.06[/C][C]432.4026[/C][C]385.9305[/C][C]478.8746[/C][C]0.0245[/C][C]0.001[/C][C]4e-04[/C][C]0[/C][/ROW]
[ROW][C]95[/C][C]526.638[/C][C]465.8805[/C][C]401.7408[/C][C]530.0202[/C][C]0.0317[/C][C]0.3436[/C][C]0.0036[/C][C]0.0036[/C][/ROW]
[ROW][C]96[/C][C]508.06[/C][C]409.1033[/C][C]320.3568[/C][C]497.8498[/C][C]0.0144[/C][C]0.0047[/C][C]0.0086[/C][C]7e-04[/C][/ROW]
[ROW][C]97[/C][C]532.394[/C][C]370.2818[/C][C]254.0564[/C][C]486.5073[/C][C]0.0031[/C][C]0.0101[/C][C]0.0112[/C][C]0.001[/C][/ROW]
[ROW][C]98[/C][C]532.115[/C][C]322.4021[/C][C]176.1976[/C][C]468.6066[/C][C]0.0025[/C][C]0.0024[/C][C]0.0179[/C][C]0.001[/C][/ROW]
[ROW][C]99[/C][C]587.896[/C][C]348.5507[/C][C]170.0836[/C][C]527.0179[/C][C]0.0043[/C][C]0.0219[/C][C]0.0252[/C][C]0.0121[/C][/ROW]
[ROW][C]100[/C][C]565.71[/C][C]284.4442[/C][C]67.1777[/C][C]501.7108[/C][C]0.0056[/C][C]0.0031[/C][C]0.0218[/C][C]0.0075[/C][/ROW]
[ROW][C]101[/C][C]572.708[/C][C]238.2935[/C][C]-21.2962[/C][C]497.8831[/C][C]0.0058[/C][C]0.0067[/C][C]0.0132[/C][C]0.0086[/C][/ROW]
[ROW][C]102[/C][C]544.417[/C][C]183.0845[/C][C]-121.9315[/C][C]488.1005[/C][C]0.0101[/C][C]0.0061[/C][C]0.0125[/C][C]0.0086[/C][/ROW]
[ROW][C]103[/C][C]597.16[/C][C]201.9038[/C][C]-151.3701[/C][C]555.1777[/C][C]0.0142[/C][C]0.0287[/C][C]0.0161[/C][C]0.0254[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=116709&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=116709&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[91])
87621.764-------
88570.214-------
89547.034-------
90511.873-------
91553.87-------
92517.058504.4447488.0092520.88020.0663000
93505.702472.953442.3768503.52920.01790.002300
94479.06432.4026385.9305478.87460.02450.0014e-040
95526.638465.8805401.7408530.02020.03170.34360.00360.0036
96508.06409.1033320.3568497.84980.01440.00470.00867e-04
97532.394370.2818254.0564486.50730.00310.01010.01120.001
98532.115322.4021176.1976468.60660.00250.00240.01790.001
99587.896348.5507170.0836527.01790.00430.02190.02520.0121
100565.71284.444267.1777501.71080.00560.00310.02180.0075
101572.708238.2935-21.2962497.88310.00580.00670.01320.0086
102544.417183.0845-121.9315488.10050.01010.00610.01250.0086
103597.16201.9038-151.3701555.17770.01420.02870.01610.0254







Univariate ARIMA Extrapolation Forecast Performance
time% S.E.PEMAPESq.EMSERMSE
920.01660.0250159.095200
930.0330.06920.04711072.4987615.79724.8153
940.05480.10790.06742176.91591136.169933.7071
950.07020.13040.08313691.47411774.99642.1307
960.11070.24190.11499792.43083378.482958.1247
970.16010.43780.168726280.35577195.461784.8261
980.23140.65050.237543979.493512450.3234111.581
990.26120.68670.293757286.150718054.8018134.3682
1000.38970.98880.370979110.429524838.7604157.6032
1010.55581.40340.4742111833.07233538.1916183.1344
1020.851.97360.6105130561.242358.4651205.8117
1030.89271.95760.7227156227.46751847.5486227.7006

\begin{tabular}{lllllllll}
\hline
Univariate ARIMA Extrapolation Forecast Performance \tabularnewline
time & % S.E. & PE & MAPE & Sq.E & MSE & RMSE \tabularnewline
92 & 0.0166 & 0.025 & 0 & 159.0952 & 0 & 0 \tabularnewline
93 & 0.033 & 0.0692 & 0.0471 & 1072.4987 & 615.797 & 24.8153 \tabularnewline
94 & 0.0548 & 0.1079 & 0.0674 & 2176.9159 & 1136.1699 & 33.7071 \tabularnewline
95 & 0.0702 & 0.1304 & 0.0831 & 3691.4741 & 1774.996 & 42.1307 \tabularnewline
96 & 0.1107 & 0.2419 & 0.1149 & 9792.4308 & 3378.4829 & 58.1247 \tabularnewline
97 & 0.1601 & 0.4378 & 0.1687 & 26280.3557 & 7195.4617 & 84.8261 \tabularnewline
98 & 0.2314 & 0.6505 & 0.2375 & 43979.4935 & 12450.3234 & 111.581 \tabularnewline
99 & 0.2612 & 0.6867 & 0.2937 & 57286.1507 & 18054.8018 & 134.3682 \tabularnewline
100 & 0.3897 & 0.9888 & 0.3709 & 79110.4295 & 24838.7604 & 157.6032 \tabularnewline
101 & 0.5558 & 1.4034 & 0.4742 & 111833.072 & 33538.1916 & 183.1344 \tabularnewline
102 & 0.85 & 1.9736 & 0.6105 & 130561.2 & 42358.4651 & 205.8117 \tabularnewline
103 & 0.8927 & 1.9576 & 0.7227 & 156227.467 & 51847.5486 & 227.7006 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=116709&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]92[/C][C]0.0166[/C][C]0.025[/C][C]0[/C][C]159.0952[/C][C]0[/C][C]0[/C][/ROW]
[ROW][C]93[/C][C]0.033[/C][C]0.0692[/C][C]0.0471[/C][C]1072.4987[/C][C]615.797[/C][C]24.8153[/C][/ROW]
[ROW][C]94[/C][C]0.0548[/C][C]0.1079[/C][C]0.0674[/C][C]2176.9159[/C][C]1136.1699[/C][C]33.7071[/C][/ROW]
[ROW][C]95[/C][C]0.0702[/C][C]0.1304[/C][C]0.0831[/C][C]3691.4741[/C][C]1774.996[/C][C]42.1307[/C][/ROW]
[ROW][C]96[/C][C]0.1107[/C][C]0.2419[/C][C]0.1149[/C][C]9792.4308[/C][C]3378.4829[/C][C]58.1247[/C][/ROW]
[ROW][C]97[/C][C]0.1601[/C][C]0.4378[/C][C]0.1687[/C][C]26280.3557[/C][C]7195.4617[/C][C]84.8261[/C][/ROW]
[ROW][C]98[/C][C]0.2314[/C][C]0.6505[/C][C]0.2375[/C][C]43979.4935[/C][C]12450.3234[/C][C]111.581[/C][/ROW]
[ROW][C]99[/C][C]0.2612[/C][C]0.6867[/C][C]0.2937[/C][C]57286.1507[/C][C]18054.8018[/C][C]134.3682[/C][/ROW]
[ROW][C]100[/C][C]0.3897[/C][C]0.9888[/C][C]0.3709[/C][C]79110.4295[/C][C]24838.7604[/C][C]157.6032[/C][/ROW]
[ROW][C]101[/C][C]0.5558[/C][C]1.4034[/C][C]0.4742[/C][C]111833.072[/C][C]33538.1916[/C][C]183.1344[/C][/ROW]
[ROW][C]102[/C][C]0.85[/C][C]1.9736[/C][C]0.6105[/C][C]130561.2[/C][C]42358.4651[/C][C]205.8117[/C][/ROW]
[ROW][C]103[/C][C]0.8927[/C][C]1.9576[/C][C]0.7227[/C][C]156227.467[/C][C]51847.5486[/C][C]227.7006[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=116709&T=2

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=116709&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
920.01660.0250159.095200
930.0330.06920.04711072.4987615.79724.8153
940.05480.10790.06742176.91591136.169933.7071
950.07020.13040.08313691.47411774.99642.1307
960.11070.24190.11499792.43083378.482958.1247
970.16010.43780.168726280.35577195.461784.8261
980.23140.65050.237543979.493512450.3234111.581
990.26120.68670.293757286.150718054.8018134.3682
1000.38970.98880.370979110.429524838.7604157.6032
1010.55581.40340.4742111833.07233538.1916183.1344
1020.851.97360.6105130561.242358.4651205.8117
1030.89271.95760.7227156227.46751847.5486227.7006



Parameters (Session):
par1 = 12 ; par2 = 1 ; par3 = 2 ; par4 = 1 ; par5 = 4 ; par6 = 1 ; par7 = 1 ; par8 = 0 ; par9 = 1 ; par10 = FALSE ;
Parameters (R input):
par1 = 12 ; par2 = 1 ; par3 = 2 ; par4 = 1 ; par5 = 4 ; par6 = 1 ; par7 = 1 ; par8 = 0 ; par9 = 1 ; par10 = FALSE ; par11 = ; par12 = ; par13 = ; par14 = ; par15 = ; par16 = ; par17 = ; par18 = ; par19 = ; par20 = ;
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')