Free Statistics

of Irreproducible Research!

Author's title

Author*Unverified author*
R Software Modulerwasp_arimaforecasting.wasp
Title produced by softwareARIMA Forecasting
Date of computationMon, 05 Dec 2011 12:58:32 -0500
Cite this page as followsStatistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?v=date/2011/Dec/05/t1323107925y9606fgmqrluegn.htm/, Retrieved Fri, 03 May 2024 08:50:03 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=151124, Retrieved Fri, 03 May 2024 08:50:03 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact122
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-     [ARIMA Forecasting] [] [2011-12-05 15:21:45] [d623f9be707a26b8ffaece1fc4d5a7ee]
- R       [ARIMA Forecasting] [] [2011-12-05 17:58:32] [d41d8cd98f00b204e9800998ecf8427e] [Current]
Feedback Forum

Post a new message
Dataseries X:
655362
873127
1107897
1555964
1671159
1493308
2957796
2638691
1305669
1280496
921900
867888
652586
913831
1108544
1555827
1699283
1509458
3268975
2425016
1312703
1365498
934453
775019
651142
843192
1146766
1652601
1465906
1652734
2922334
2702805
1458956
1410363
1019279
936574
708917
885295
1099663
1576220
1487870
1488635
2882530
2677026
1404398
1344370
936865
872705
628151
953712
1160384
1400618
1661511
1495347
2918786
2775677
1407026
1370199
964526
850851
683118
847224
1073256
1514326
1503734
1507712
2865698
2788128
1391596
1366378
946295
859626




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

\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 & 'AstonUniversity' @ aston.wessa.net \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=151124&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]'AstonUniversity' @ aston.wessa.net[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=151124&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=151124&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'AstonUniversity' @ aston.wessa.net







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[60])
59964526-------
60850851-------
61683118861812.6566-252388.62451976013.93770.37660.50770.50770.5077
62847224772611.2456-949582.25782494804.74890.46620.54060.54060.4645
631073256855298.1369-1115468.3722826064.64580.41420.50320.50320.5018
641514326761477.4701-1567744.68123090699.62150.26320.39650.39650.47
651503734821194.8572-1809244.50363451634.2180.30550.30280.30280.4912
661507712802221.9235-2125772.45113730216.29820.31840.31930.31930.487
672865698794277.5868-2390973.68583979528.85930.10120.33030.33030.4861
682788128820086.9889-2612190.87584252364.85370.13050.12140.12140.493
691391596793033.2128-2892702.73474478769.16030.37510.14440.14440.4877
701366378820697.6053-3088090.24584729485.45630.39220.38730.38730.494
71946295804669.1297-3334539.20084943877.46020.47330.39510.39510.4913
72859626814235.9246-3540830.07895169301.92820.49190.47630.47630.4934

\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[60]) \tabularnewline
59 & 964526 & - & - & - & - & - & - & - \tabularnewline
60 & 850851 & - & - & - & - & - & - & - \tabularnewline
61 & 683118 & 861812.6566 & -252388.6245 & 1976013.9377 & 0.3766 & 0.5077 & 0.5077 & 0.5077 \tabularnewline
62 & 847224 & 772611.2456 & -949582.2578 & 2494804.7489 & 0.4662 & 0.5406 & 0.5406 & 0.4645 \tabularnewline
63 & 1073256 & 855298.1369 & -1115468.372 & 2826064.6458 & 0.4142 & 0.5032 & 0.5032 & 0.5018 \tabularnewline
64 & 1514326 & 761477.4701 & -1567744.6812 & 3090699.6215 & 0.2632 & 0.3965 & 0.3965 & 0.47 \tabularnewline
65 & 1503734 & 821194.8572 & -1809244.5036 & 3451634.218 & 0.3055 & 0.3028 & 0.3028 & 0.4912 \tabularnewline
66 & 1507712 & 802221.9235 & -2125772.4511 & 3730216.2982 & 0.3184 & 0.3193 & 0.3193 & 0.487 \tabularnewline
67 & 2865698 & 794277.5868 & -2390973.6858 & 3979528.8593 & 0.1012 & 0.3303 & 0.3303 & 0.4861 \tabularnewline
68 & 2788128 & 820086.9889 & -2612190.8758 & 4252364.8537 & 0.1305 & 0.1214 & 0.1214 & 0.493 \tabularnewline
69 & 1391596 & 793033.2128 & -2892702.7347 & 4478769.1603 & 0.3751 & 0.1444 & 0.1444 & 0.4877 \tabularnewline
70 & 1366378 & 820697.6053 & -3088090.2458 & 4729485.4563 & 0.3922 & 0.3873 & 0.3873 & 0.494 \tabularnewline
71 & 946295 & 804669.1297 & -3334539.2008 & 4943877.4602 & 0.4733 & 0.3951 & 0.3951 & 0.4913 \tabularnewline
72 & 859626 & 814235.9246 & -3540830.0789 & 5169301.9282 & 0.4919 & 0.4763 & 0.4763 & 0.4934 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=151124&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[60])[/C][/ROW]
[ROW][C]59[/C][C]964526[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]60[/C][C]850851[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]61[/C][C]683118[/C][C]861812.6566[/C][C]-252388.6245[/C][C]1976013.9377[/C][C]0.3766[/C][C]0.5077[/C][C]0.5077[/C][C]0.5077[/C][/ROW]
[ROW][C]62[/C][C]847224[/C][C]772611.2456[/C][C]-949582.2578[/C][C]2494804.7489[/C][C]0.4662[/C][C]0.5406[/C][C]0.5406[/C][C]0.4645[/C][/ROW]
[ROW][C]63[/C][C]1073256[/C][C]855298.1369[/C][C]-1115468.372[/C][C]2826064.6458[/C][C]0.4142[/C][C]0.5032[/C][C]0.5032[/C][C]0.5018[/C][/ROW]
[ROW][C]64[/C][C]1514326[/C][C]761477.4701[/C][C]-1567744.6812[/C][C]3090699.6215[/C][C]0.2632[/C][C]0.3965[/C][C]0.3965[/C][C]0.47[/C][/ROW]
[ROW][C]65[/C][C]1503734[/C][C]821194.8572[/C][C]-1809244.5036[/C][C]3451634.218[/C][C]0.3055[/C][C]0.3028[/C][C]0.3028[/C][C]0.4912[/C][/ROW]
[ROW][C]66[/C][C]1507712[/C][C]802221.9235[/C][C]-2125772.4511[/C][C]3730216.2982[/C][C]0.3184[/C][C]0.3193[/C][C]0.3193[/C][C]0.487[/C][/ROW]
[ROW][C]67[/C][C]2865698[/C][C]794277.5868[/C][C]-2390973.6858[/C][C]3979528.8593[/C][C]0.1012[/C][C]0.3303[/C][C]0.3303[/C][C]0.4861[/C][/ROW]
[ROW][C]68[/C][C]2788128[/C][C]820086.9889[/C][C]-2612190.8758[/C][C]4252364.8537[/C][C]0.1305[/C][C]0.1214[/C][C]0.1214[/C][C]0.493[/C][/ROW]
[ROW][C]69[/C][C]1391596[/C][C]793033.2128[/C][C]-2892702.7347[/C][C]4478769.1603[/C][C]0.3751[/C][C]0.1444[/C][C]0.1444[/C][C]0.4877[/C][/ROW]
[ROW][C]70[/C][C]1366378[/C][C]820697.6053[/C][C]-3088090.2458[/C][C]4729485.4563[/C][C]0.3922[/C][C]0.3873[/C][C]0.3873[/C][C]0.494[/C][/ROW]
[ROW][C]71[/C][C]946295[/C][C]804669.1297[/C][C]-3334539.2008[/C][C]4943877.4602[/C][C]0.4733[/C][C]0.3951[/C][C]0.3951[/C][C]0.4913[/C][/ROW]
[ROW][C]72[/C][C]859626[/C][C]814235.9246[/C][C]-3540830.0789[/C][C]5169301.9282[/C][C]0.4919[/C][C]0.4763[/C][C]0.4763[/C][C]0.4934[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=151124&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=151124&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[60])
59964526-------
60850851-------
61683118861812.6566-252388.62451976013.93770.37660.50770.50770.5077
62847224772611.2456-949582.25782494804.74890.46620.54060.54060.4645
631073256855298.1369-1115468.3722826064.64580.41420.50320.50320.5018
641514326761477.4701-1567744.68123090699.62150.26320.39650.39650.47
651503734821194.8572-1809244.50363451634.2180.30550.30280.30280.4912
661507712802221.9235-2125772.45113730216.29820.31840.31930.31930.487
672865698794277.5868-2390973.68583979528.85930.10120.33030.33030.4861
682788128820086.9889-2612190.87584252364.85370.13050.12140.12140.493
691391596793033.2128-2892702.73474478769.16030.37510.14440.14440.4877
701366378820697.6053-3088090.24584729485.45630.39220.38730.38730.494
71946295804669.1297-3334539.20084943877.46020.47330.39510.39510.4913
72859626814235.9246-3540830.07895169301.92820.49190.47630.47630.4934







Univariate ARIMA Extrapolation Forecast Performance
time% S.E.PEMAPESq.EMSERMSE
610.6596-0.2073031931780292.100700
621.13730.09660.1525567063125.581918749421708.8413136928.5277
631.17560.25480.186347505630103.911228334824507.1979168329.5117
641.56060.98870.3869566780908915.042162946345609.159403666.1314
651.63430.83120.4757465859681501.845223529012787.696472788.5498
661.86220.87940.543497716247999.713269226885323.033518870.779
672.0462.60790.8384290782528331.32843734834324.216918550.3984
682.13532.39981.03323873185421302.411222416157696.491105629.3039
692.37120.75481.0023358277410225.0961126400741310.781061320.2822
702.430.66490.9685297767093195.6761043537376499.271021536.772
712.62450.1760.896520057887144.1267950493786557.892974932.7087
722.72890.05570.82642060258940.6782871457659256.458933518.9657

\begin{tabular}{lllllllll}
\hline
Univariate ARIMA Extrapolation Forecast Performance \tabularnewline
time & % S.E. & PE & MAPE & Sq.E & MSE & RMSE \tabularnewline
61 & 0.6596 & -0.2073 & 0 & 31931780292.1007 & 0 & 0 \tabularnewline
62 & 1.1373 & 0.0966 & 0.152 & 5567063125.5819 & 18749421708.8413 & 136928.5277 \tabularnewline
63 & 1.1756 & 0.2548 & 0.1863 & 47505630103.9112 & 28334824507.1979 & 168329.5117 \tabularnewline
64 & 1.5606 & 0.9887 & 0.3869 & 566780908915.042 & 162946345609.159 & 403666.1314 \tabularnewline
65 & 1.6343 & 0.8312 & 0.4757 & 465859681501.845 & 223529012787.696 & 472788.5498 \tabularnewline
66 & 1.8622 & 0.8794 & 0.543 & 497716247999.713 & 269226885323.033 & 518870.779 \tabularnewline
67 & 2.046 & 2.6079 & 0.838 & 4290782528331.32 & 843734834324.216 & 918550.3984 \tabularnewline
68 & 2.1353 & 2.3998 & 1.0332 & 3873185421302.41 & 1222416157696.49 & 1105629.3039 \tabularnewline
69 & 2.3712 & 0.7548 & 1.0023 & 358277410225.096 & 1126400741310.78 & 1061320.2822 \tabularnewline
70 & 2.43 & 0.6649 & 0.9685 & 297767093195.676 & 1043537376499.27 & 1021536.772 \tabularnewline
71 & 2.6245 & 0.176 & 0.8965 & 20057887144.1267 & 950493786557.892 & 974932.7087 \tabularnewline
72 & 2.7289 & 0.0557 & 0.8264 & 2060258940.6782 & 871457659256.458 & 933518.9657 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=151124&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]61[/C][C]0.6596[/C][C]-0.2073[/C][C]0[/C][C]31931780292.1007[/C][C]0[/C][C]0[/C][/ROW]
[ROW][C]62[/C][C]1.1373[/C][C]0.0966[/C][C]0.152[/C][C]5567063125.5819[/C][C]18749421708.8413[/C][C]136928.5277[/C][/ROW]
[ROW][C]63[/C][C]1.1756[/C][C]0.2548[/C][C]0.1863[/C][C]47505630103.9112[/C][C]28334824507.1979[/C][C]168329.5117[/C][/ROW]
[ROW][C]64[/C][C]1.5606[/C][C]0.9887[/C][C]0.3869[/C][C]566780908915.042[/C][C]162946345609.159[/C][C]403666.1314[/C][/ROW]
[ROW][C]65[/C][C]1.6343[/C][C]0.8312[/C][C]0.4757[/C][C]465859681501.845[/C][C]223529012787.696[/C][C]472788.5498[/C][/ROW]
[ROW][C]66[/C][C]1.8622[/C][C]0.8794[/C][C]0.543[/C][C]497716247999.713[/C][C]269226885323.033[/C][C]518870.779[/C][/ROW]
[ROW][C]67[/C][C]2.046[/C][C]2.6079[/C][C]0.838[/C][C]4290782528331.32[/C][C]843734834324.216[/C][C]918550.3984[/C][/ROW]
[ROW][C]68[/C][C]2.1353[/C][C]2.3998[/C][C]1.0332[/C][C]3873185421302.41[/C][C]1222416157696.49[/C][C]1105629.3039[/C][/ROW]
[ROW][C]69[/C][C]2.3712[/C][C]0.7548[/C][C]1.0023[/C][C]358277410225.096[/C][C]1126400741310.78[/C][C]1061320.2822[/C][/ROW]
[ROW][C]70[/C][C]2.43[/C][C]0.6649[/C][C]0.9685[/C][C]297767093195.676[/C][C]1043537376499.27[/C][C]1021536.772[/C][/ROW]
[ROW][C]71[/C][C]2.6245[/C][C]0.176[/C][C]0.8965[/C][C]20057887144.1267[/C][C]950493786557.892[/C][C]974932.7087[/C][/ROW]
[ROW][C]72[/C][C]2.7289[/C][C]0.0557[/C][C]0.8264[/C][C]2060258940.6782[/C][C]871457659256.458[/C][C]933518.9657[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=151124&T=2

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=151124&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
610.6596-0.2073031931780292.100700
621.13730.09660.1525567063125.581918749421708.8413136928.5277
631.17560.25480.186347505630103.911228334824507.1979168329.5117
641.56060.98870.3869566780908915.042162946345609.159403666.1314
651.63430.83120.4757465859681501.845223529012787.696472788.5498
661.86220.87940.543497716247999.713269226885323.033518870.779
672.0462.60790.8384290782528331.32843734834324.216918550.3984
682.13532.39981.03323873185421302.411222416157696.491105629.3039
692.37120.75481.0023358277410225.0961126400741310.781061320.2822
702.430.66490.9685297767093195.6761043537376499.271021536.772
712.62450.1760.896520057887144.1267950493786557.892974932.7087
722.72890.05570.82642060258940.6782871457659256.458933518.9657



Parameters (Session):
par1 = 12 ; par2 = 1 ; par3 = 1 ; par4 = 1 ; par5 = 1 ; par6 = 3 ; par7 = 2 ; par8 = 2 ; par9 = 1 ; par10 = TRUE ;
Parameters (R input):
par1 = 12 ; par2 = 1 ; par3 = 1 ; par4 = 1 ; par5 = 1 ; par6 = 3 ; par7 = 2 ; par8 = 2 ; par9 = 1 ; par10 = TRUE ;
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')