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 computationTue, 07 Dec 2010 11:53:51 +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/07/t1291722823ic22v9z6bgfaj8p.htm/, Retrieved Sat, 04 May 2024 03:09:48 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=106202, Retrieved Sat, 04 May 2024 03:09:48 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact113
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   [Standard Deviation-Mean Plot] [Unemployment] [2010-11-29 10:34:47] [b98453cac15ba1066b407e146608df68]
- RMP     [ARIMA Backward Selection] [Unemployment] [2010-11-29 17:10:28] [b98453cac15ba1066b407e146608df68]
- R PD      [ARIMA Backward Selection] [Workshop 9; Coffe...] [2010-12-07 11:14:19] [8ffb4cfa64b4677df0d2c448735a40bb]
- RM D          [ARIMA Forecasting] [Workshop 9; Coffe...] [2010-12-07 11:53:51] [50e0b5177c9c80b42996aa89930b928a] [Current]
Feedback Forum

Post a new message
Dataseries X:
168,67
164,83
184,38
180,81
190,54
181,41
155,67
135,99
125,88
126,09
114,86
127,98
127,98
125,11
125,93
128,2
125,93
111,94
120,01
124,09
126,02
136,41
143,79
141,67
143,9
155
144,83
141,4
137
141,02
131,11
132,83
136,73
141,18
137,86
133,79
128,53
125,87
124,27
123,96
128,15
126,4
127,86
129,31
132,56
141,28
145,55
146,54
143,14
145,72
148,21
150,4
149,94
146,66
143,37
145,29
140,24
136,12
140,25
140,64
145,58
143,73
141,27
140,66
141,94
141,16
134,31
132,93
133,07
140,48
154,85
196,77
235,3
226,52
237,62
224,07
208,74
174,54
170,63
172,23
198,36
175,91
154,63
134,31
121,75
119,6
102,04
106,3
116,38
103,72
98,56
100,9
110
118,26
124,77
125,22
126,38
137,14
134,74
134,3
136,39
141,83
139,24
128,89
134,83
130,43
132,09
144,95
149,5
137,57
139,38
143,06
138,65
123,21
85,91
77,4
77,84
67,76
70,72
72,55
75,83
84,01
93,96
93,73
92,02
88,26
86,48
94,42
94,92
91,41
84,84
89,89
86,32
89,57
93,72
92,27
87,59
85,5
82,81
81,62
87,45
79,86
78,52
75,1
72,99
67,88
70,14
65,43
60,26
58,38
57,68
52,42
52,73
61,4
67,13
77,46
68,66
67,46
62,77
56,88
61,48
61,99
71,56
76,56
79,82
75,05
77,07
80
77,21
82,16
85,57
89,23
121,98
142,56
217,67
198,07
220,1
198,68
181,64
167,47
172,33
168,71
178,22
172,81
168,83
152,25
143,83
151,41
131,87
125,38
123,23
103,99
109,38
123,79
119,05
122,01
128,56
127,91
120,47
122,49
114,05
120,62
119,61
115,01
131,83
167,2
193,82
204,43
264,5
212,55
186,52
185,17
184,38
161,45
154,15
174,25
175,04
175,87
154,82
147,08
134,35
121,56
113,86
119,89
108,07
107,07
115,14
116,03
111,48
103,24
103,23
99,69
108,91
104,21
90,85
87,64
81,06
92,2
114,02
123,56
109,17
101,65
97,95
92,56
91,76
84,1
84,67
74,52
73,83
75,37
70,47
64,5
64,98
66,94
65,93
65,51
68,94
63,67
58,47
59,68
57,71
56,53
58,96
55,6
57,34
60,51
66,38
65,78
58,43
55,16
53,09
52,02
57,58
64,05
70,18
63,86
65,22
67,6
61,66
65,32
66,18
61,34
62,29
63,6
65,51
62,58
62,36
64,88
73,73
77,51
77,47
74,34
75,81
82,16
73,96
73,17
80,99
79,81
89,51
102,57
107,11
122,23
134,69
128,79
126,16
119,98
108,45
108,43
98,17
106,09
108,81
103,03
124,36
118,52
112,2
114,71
107,96
101,21
102,77
112,13
109,36
110,91
123,57
129,95
124,46
122,34
116,61
114,59
112,52
118,67
116,8
123,63
128,04
134,57
130,33
136,47
139,05
158,21
148,07
137,74
139,74
144,08
145,35
145,77
140,56
121,41
120,44
116,97
128,03
128,51
127,76
134,58
147,64
144,46
137,6
146,87
145,67
151,95
150,23
155,86
154,4
156,36
162,13
171,06
174,01
193,52
205,26
212,8
222,1




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=106202&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=106202&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=106202&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[357])
345140.56-------
346121.41-------
347120.44-------
348116.97-------
349128.03-------
350128.51-------
351127.76-------
352134.58-------
353147.64-------
354144.46-------
355137.6-------
356146.87-------
357145.67-------
358151.95145.4049123.563173.05920.32140.49250.95550.4925
359150.23145.346112.9233192.46240.41950.39180.84990.4946
360155.86145.3329105.5687209.69260.37430.44070.80610.4959
361154.4145.3399.9759225.67090.41240.39860.66350.4967
362156.36145.329395.4543240.95550.41060.42630.63490.4972
363162.13145.329291.6503255.87940.38290.42250.62230.4976
364171.06145.329188.3622270.64990.34370.39640.56680.4979
365174.01145.329185.4647285.40450.34410.35940.48710.4981
366193.52145.329182.8741300.2410.2710.35830.50440.4983
367205.26145.329180.5318315.23330.24470.28910.53550.4984
368212.8145.329178.3949330.44030.23750.26290.49350.4986
369222.1145.329176.4309345.91110.22660.25490.49870.4987

\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[357]) \tabularnewline
345 & 140.56 & - & - & - & - & - & - & - \tabularnewline
346 & 121.41 & - & - & - & - & - & - & - \tabularnewline
347 & 120.44 & - & - & - & - & - & - & - \tabularnewline
348 & 116.97 & - & - & - & - & - & - & - \tabularnewline
349 & 128.03 & - & - & - & - & - & - & - \tabularnewline
350 & 128.51 & - & - & - & - & - & - & - \tabularnewline
351 & 127.76 & - & - & - & - & - & - & - \tabularnewline
352 & 134.58 & - & - & - & - & - & - & - \tabularnewline
353 & 147.64 & - & - & - & - & - & - & - \tabularnewline
354 & 144.46 & - & - & - & - & - & - & - \tabularnewline
355 & 137.6 & - & - & - & - & - & - & - \tabularnewline
356 & 146.87 & - & - & - & - & - & - & - \tabularnewline
357 & 145.67 & - & - & - & - & - & - & - \tabularnewline
358 & 151.95 & 145.4049 & 123.563 & 173.0592 & 0.3214 & 0.4925 & 0.9555 & 0.4925 \tabularnewline
359 & 150.23 & 145.346 & 112.9233 & 192.4624 & 0.4195 & 0.3918 & 0.8499 & 0.4946 \tabularnewline
360 & 155.86 & 145.3329 & 105.5687 & 209.6926 & 0.3743 & 0.4407 & 0.8061 & 0.4959 \tabularnewline
361 & 154.4 & 145.33 & 99.9759 & 225.6709 & 0.4124 & 0.3986 & 0.6635 & 0.4967 \tabularnewline
362 & 156.36 & 145.3293 & 95.4543 & 240.9555 & 0.4106 & 0.4263 & 0.6349 & 0.4972 \tabularnewline
363 & 162.13 & 145.3292 & 91.6503 & 255.8794 & 0.3829 & 0.4225 & 0.6223 & 0.4976 \tabularnewline
364 & 171.06 & 145.3291 & 88.3622 & 270.6499 & 0.3437 & 0.3964 & 0.5668 & 0.4979 \tabularnewline
365 & 174.01 & 145.3291 & 85.4647 & 285.4045 & 0.3441 & 0.3594 & 0.4871 & 0.4981 \tabularnewline
366 & 193.52 & 145.3291 & 82.8741 & 300.241 & 0.271 & 0.3583 & 0.5044 & 0.4983 \tabularnewline
367 & 205.26 & 145.3291 & 80.5318 & 315.2333 & 0.2447 & 0.2891 & 0.5355 & 0.4984 \tabularnewline
368 & 212.8 & 145.3291 & 78.3949 & 330.4403 & 0.2375 & 0.2629 & 0.4935 & 0.4986 \tabularnewline
369 & 222.1 & 145.3291 & 76.4309 & 345.9111 & 0.2266 & 0.2549 & 0.4987 & 0.4987 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=106202&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[357])[/C][/ROW]
[ROW][C]345[/C][C]140.56[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]346[/C][C]121.41[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]347[/C][C]120.44[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]348[/C][C]116.97[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]349[/C][C]128.03[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]350[/C][C]128.51[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]351[/C][C]127.76[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]352[/C][C]134.58[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]353[/C][C]147.64[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]354[/C][C]144.46[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]355[/C][C]137.6[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]356[/C][C]146.87[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]357[/C][C]145.67[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][C]-[/C][/ROW]
[ROW][C]358[/C][C]151.95[/C][C]145.4049[/C][C]123.563[/C][C]173.0592[/C][C]0.3214[/C][C]0.4925[/C][C]0.9555[/C][C]0.4925[/C][/ROW]
[ROW][C]359[/C][C]150.23[/C][C]145.346[/C][C]112.9233[/C][C]192.4624[/C][C]0.4195[/C][C]0.3918[/C][C]0.8499[/C][C]0.4946[/C][/ROW]
[ROW][C]360[/C][C]155.86[/C][C]145.3329[/C][C]105.5687[/C][C]209.6926[/C][C]0.3743[/C][C]0.4407[/C][C]0.8061[/C][C]0.4959[/C][/ROW]
[ROW][C]361[/C][C]154.4[/C][C]145.33[/C][C]99.9759[/C][C]225.6709[/C][C]0.4124[/C][C]0.3986[/C][C]0.6635[/C][C]0.4967[/C][/ROW]
[ROW][C]362[/C][C]156.36[/C][C]145.3293[/C][C]95.4543[/C][C]240.9555[/C][C]0.4106[/C][C]0.4263[/C][C]0.6349[/C][C]0.4972[/C][/ROW]
[ROW][C]363[/C][C]162.13[/C][C]145.3292[/C][C]91.6503[/C][C]255.8794[/C][C]0.3829[/C][C]0.4225[/C][C]0.6223[/C][C]0.4976[/C][/ROW]
[ROW][C]364[/C][C]171.06[/C][C]145.3291[/C][C]88.3622[/C][C]270.6499[/C][C]0.3437[/C][C]0.3964[/C][C]0.5668[/C][C]0.4979[/C][/ROW]
[ROW][C]365[/C][C]174.01[/C][C]145.3291[/C][C]85.4647[/C][C]285.4045[/C][C]0.3441[/C][C]0.3594[/C][C]0.4871[/C][C]0.4981[/C][/ROW]
[ROW][C]366[/C][C]193.52[/C][C]145.3291[/C][C]82.8741[/C][C]300.241[/C][C]0.271[/C][C]0.3583[/C][C]0.5044[/C][C]0.4983[/C][/ROW]
[ROW][C]367[/C][C]205.26[/C][C]145.3291[/C][C]80.5318[/C][C]315.2333[/C][C]0.2447[/C][C]0.2891[/C][C]0.5355[/C][C]0.4984[/C][/ROW]
[ROW][C]368[/C][C]212.8[/C][C]145.3291[/C][C]78.3949[/C][C]330.4403[/C][C]0.2375[/C][C]0.2629[/C][C]0.4935[/C][C]0.4986[/C][/ROW]
[ROW][C]369[/C][C]222.1[/C][C]145.3291[/C][C]76.4309[/C][C]345.9111[/C][C]0.2266[/C][C]0.2549[/C][C]0.4987[/C][C]0.4987[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=106202&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=106202&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[357])
345140.56-------
346121.41-------
347120.44-------
348116.97-------
349128.03-------
350128.51-------
351127.76-------
352134.58-------
353147.64-------
354144.46-------
355137.6-------
356146.87-------
357145.67-------
358151.95145.4049123.563173.05920.32140.49250.95550.4925
359150.23145.346112.9233192.46240.41950.39180.84990.4946
360155.86145.3329105.5687209.69260.37430.44070.80610.4959
361154.4145.3399.9759225.67090.41240.39860.66350.4967
362156.36145.329395.4543240.95550.41060.42630.63490.4972
363162.13145.329291.6503255.87940.38290.42250.62230.4976
364171.06145.329188.3622270.64990.34370.39640.56680.4979
365174.01145.329185.4647285.40450.34410.35940.48710.4981
366193.52145.329182.8741300.2410.2710.35830.50440.4983
367205.26145.329180.5318315.23330.24470.28910.53550.4984
368212.8145.329178.3949330.44030.23750.26290.49350.4986
369222.1145.329176.4309345.91110.22660.25490.49870.4987







Univariate ARIMA Extrapolation Forecast Performance
time% S.E.PEMAPESq.EMSERMSE
3580.0970.045042.838600
3590.16540.03360.039323.853633.34615.7746
3600.22590.07240.0504110.820159.17087.6923
3610.2820.06240.053482.265464.94448.0588
3620.33570.07590.0579121.675876.29078.7345
3630.38810.11560.0675282.2676110.620210.5176
3640.440.17710.0831662.0768189.399713.7623
3650.49180.19740.0974822.5917268.548716.3875
3660.54380.33160.12342322.3591496.749922.2879
3670.59650.41240.15233591.7082806.245728.3945
3680.64990.46430.18074552.31721146.797633.8644
3690.70420.52830.20975893.76521542.378339.2731

\begin{tabular}{lllllllll}
\hline
Univariate ARIMA Extrapolation Forecast Performance \tabularnewline
time & % S.E. & PE & MAPE & Sq.E & MSE & RMSE \tabularnewline
358 & 0.097 & 0.045 & 0 & 42.8386 & 0 & 0 \tabularnewline
359 & 0.1654 & 0.0336 & 0.0393 & 23.8536 & 33.3461 & 5.7746 \tabularnewline
360 & 0.2259 & 0.0724 & 0.0504 & 110.8201 & 59.1708 & 7.6923 \tabularnewline
361 & 0.282 & 0.0624 & 0.0534 & 82.2654 & 64.9444 & 8.0588 \tabularnewline
362 & 0.3357 & 0.0759 & 0.0579 & 121.6758 & 76.2907 & 8.7345 \tabularnewline
363 & 0.3881 & 0.1156 & 0.0675 & 282.2676 & 110.6202 & 10.5176 \tabularnewline
364 & 0.44 & 0.1771 & 0.0831 & 662.0768 & 189.3997 & 13.7623 \tabularnewline
365 & 0.4918 & 0.1974 & 0.0974 & 822.5917 & 268.5487 & 16.3875 \tabularnewline
366 & 0.5438 & 0.3316 & 0.1234 & 2322.3591 & 496.7499 & 22.2879 \tabularnewline
367 & 0.5965 & 0.4124 & 0.1523 & 3591.7082 & 806.2457 & 28.3945 \tabularnewline
368 & 0.6499 & 0.4643 & 0.1807 & 4552.3172 & 1146.7976 & 33.8644 \tabularnewline
369 & 0.7042 & 0.5283 & 0.2097 & 5893.7652 & 1542.3783 & 39.2731 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=106202&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]358[/C][C]0.097[/C][C]0.045[/C][C]0[/C][C]42.8386[/C][C]0[/C][C]0[/C][/ROW]
[ROW][C]359[/C][C]0.1654[/C][C]0.0336[/C][C]0.0393[/C][C]23.8536[/C][C]33.3461[/C][C]5.7746[/C][/ROW]
[ROW][C]360[/C][C]0.2259[/C][C]0.0724[/C][C]0.0504[/C][C]110.8201[/C][C]59.1708[/C][C]7.6923[/C][/ROW]
[ROW][C]361[/C][C]0.282[/C][C]0.0624[/C][C]0.0534[/C][C]82.2654[/C][C]64.9444[/C][C]8.0588[/C][/ROW]
[ROW][C]362[/C][C]0.3357[/C][C]0.0759[/C][C]0.0579[/C][C]121.6758[/C][C]76.2907[/C][C]8.7345[/C][/ROW]
[ROW][C]363[/C][C]0.3881[/C][C]0.1156[/C][C]0.0675[/C][C]282.2676[/C][C]110.6202[/C][C]10.5176[/C][/ROW]
[ROW][C]364[/C][C]0.44[/C][C]0.1771[/C][C]0.0831[/C][C]662.0768[/C][C]189.3997[/C][C]13.7623[/C][/ROW]
[ROW][C]365[/C][C]0.4918[/C][C]0.1974[/C][C]0.0974[/C][C]822.5917[/C][C]268.5487[/C][C]16.3875[/C][/ROW]
[ROW][C]366[/C][C]0.5438[/C][C]0.3316[/C][C]0.1234[/C][C]2322.3591[/C][C]496.7499[/C][C]22.2879[/C][/ROW]
[ROW][C]367[/C][C]0.5965[/C][C]0.4124[/C][C]0.1523[/C][C]3591.7082[/C][C]806.2457[/C][C]28.3945[/C][/ROW]
[ROW][C]368[/C][C]0.6499[/C][C]0.4643[/C][C]0.1807[/C][C]4552.3172[/C][C]1146.7976[/C][C]33.8644[/C][/ROW]
[ROW][C]369[/C][C]0.7042[/C][C]0.5283[/C][C]0.2097[/C][C]5893.7652[/C][C]1542.3783[/C][C]39.2731[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=106202&T=2

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=106202&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
3580.0970.045042.838600
3590.16540.03360.039323.853633.34615.7746
3600.22590.07240.0504110.820159.17087.6923
3610.2820.06240.053482.265464.94448.0588
3620.33570.07590.0579121.675876.29078.7345
3630.38810.11560.0675282.2676110.620210.5176
3640.440.17710.0831662.0768189.399713.7623
3650.49180.19740.0974822.5917268.548716.3875
3660.54380.33160.12342322.3591496.749922.2879
3670.59650.41240.15233591.7082806.245728.3945
3680.64990.46430.18074552.31721146.797633.8644
3690.70420.52830.20975893.76521542.378339.2731



Parameters (Session):
par1 = 12 ;
Parameters (R input):
par1 = 12 ; par2 = -0.4 ; par3 = 1 ; par4 = 0 ; par5 = 12 ; par6 = 1 ; 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')