Free Statistics

of Irreproducible Research!

Author's title

Author*Unverified author*
R Software Modulerwasp_exponentialsmoothing.wasp
Title produced by softwareExponential Smoothing
Date of computationMon, 16 May 2016 00:03:57 +0100
Cite this page as followsStatistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?v=date/2016/May/16/t1463353496oezh551ghyks22b.htm/, Retrieved Wed, 22 May 2024 05:27:46 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=295374, Retrieved Wed, 22 May 2024 05:27:46 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact141
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-       [Exponential Smoothing] [] [2016-05-15 23:03:57] [517bf63cbd197750110a40d4d2cd39d6] [Current]
Feedback Forum

Post a new message
Dataseries X:
74787
49019
56601
47637
49806
50499
42092
39062
44382
43635
41082
17244
70170
43949
52333
41032
47758
76116
30917
32996
31951
26775
30268
18214
47957
31901
35559
30408
30083
35043
30475
28309
31394
36313
40357
38918
44368
33298
29366
28282
30943
32699
29764
25524
29807
35112
32192
36214
47639
33421
28642
26996
27757
36839
33821
30839
35032
38821
40347
68799




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time2 seconds
R Server'Sir Ronald Aylmer Fisher' @ fisher.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 & 'Sir Ronald Aylmer Fisher' @ fisher.wessa.net \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=295374&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]'Sir Ronald Aylmer Fisher' @ fisher.wessa.net[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=295374&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=295374&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'Sir Ronald Aylmer Fisher' @ fisher.wessa.net







Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.133767066761676
beta0.0653253586791774
gamma1

\begin{tabular}{lllllllll}
\hline
Estimated Parameters of Exponential Smoothing \tabularnewline
Parameter & Value \tabularnewline
alpha & 0.133767066761676 \tabularnewline
beta & 0.0653253586791774 \tabularnewline
gamma & 1 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=295374&T=1

[TABLE]
[ROW][C]Estimated Parameters of Exponential Smoothing[/C][/ROW]
[ROW][C]Parameter[/C][C]Value[/C][/ROW]
[ROW][C]alpha[/C][C]0.133767066761676[/C][/ROW]
[ROW][C]beta[/C][C]0.0653253586791774[/C][/ROW]
[ROW][C]gamma[/C][C]1[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=295374&T=1

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

As an alternative you can also use a QR Code:  

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

Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.133767066761676
beta0.0653253586791774
gamma1







Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
137017067335.66249348482834.33750651521
144394942806.65596717941142.34403282056
155233351716.2593668158616.740633184156
164103241500.027621029-468.027621029032
174775849236.2448308695-1478.24483086947
187611678403.241493294-2287.24149329403
193091738895.3921112922-7978.39211129224
203299635096.1972138899-2100.19721388991
213195139510.0504450047-7559.05044500469
222677537783.734617154-11008.734617154
233026833945.7869225516-3677.78692255155
241821413513.24470683344700.75529316659
254795758086.8461342323-10129.8461342323
263190135095.6554438181-3194.6554438181
273555940795.2226771601-5236.22267716011
283040831106.2356087655-698.235608765495
293008335791.0876861243-5708.08768612425
303504355242.3927448331-20199.3927448331
313047521527.73995947158947.26004052853
322830924138.58640089454170.4135991055
333139424285.21831859337108.78168140668
343631321883.389435986214429.6105640138
354035727432.551583481212924.4484165188
363891816938.584509999421979.4154900006
374436854525.1967766752-10157.1967766752
383329836445.2291981026-3147.2291981026
392936641611.3182312758-12245.3182312758
402828234888.7957084244-6606.79570842441
413094334940.0914696705-3997.09146967054
423269942882.2362591249-10183.2362591249
432976434904.3024580426-5140.30245804261
442552431519.9410905748-5995.94109057475
452980733143.8406174388-3336.84061743884
463511234999.0324079421112.967592057867
473219236621.4935260126-4429.49352601259
483621429445.96668547086768.03331452919
494763934999.403355184112639.5966448159
503342127612.49494132785808.50505867224
512864225902.79323779212739.20676220794
522699625889.43197532121106.56802467881
532775728915.3284121261-1158.32841212612
543683931395.23799539715443.7620046029
553382129947.60445567443873.39554432555
563083926986.16201736493852.83798263506
573503232876.41010437322155.58989562679
583882139502.5245645302-681.524564530198
594034737150.46695736963196.53304263038
606879941571.036141476227227.9638585238

\begin{tabular}{lllllllll}
\hline
Interpolation Forecasts of Exponential Smoothing \tabularnewline
t & Observed & Fitted & Residuals \tabularnewline
13 & 70170 & 67335.6624934848 & 2834.33750651521 \tabularnewline
14 & 43949 & 42806.6559671794 & 1142.34403282056 \tabularnewline
15 & 52333 & 51716.2593668158 & 616.740633184156 \tabularnewline
16 & 41032 & 41500.027621029 & -468.027621029032 \tabularnewline
17 & 47758 & 49236.2448308695 & -1478.24483086947 \tabularnewline
18 & 76116 & 78403.241493294 & -2287.24149329403 \tabularnewline
19 & 30917 & 38895.3921112922 & -7978.39211129224 \tabularnewline
20 & 32996 & 35096.1972138899 & -2100.19721388991 \tabularnewline
21 & 31951 & 39510.0504450047 & -7559.05044500469 \tabularnewline
22 & 26775 & 37783.734617154 & -11008.734617154 \tabularnewline
23 & 30268 & 33945.7869225516 & -3677.78692255155 \tabularnewline
24 & 18214 & 13513.2447068334 & 4700.75529316659 \tabularnewline
25 & 47957 & 58086.8461342323 & -10129.8461342323 \tabularnewline
26 & 31901 & 35095.6554438181 & -3194.6554438181 \tabularnewline
27 & 35559 & 40795.2226771601 & -5236.22267716011 \tabularnewline
28 & 30408 & 31106.2356087655 & -698.235608765495 \tabularnewline
29 & 30083 & 35791.0876861243 & -5708.08768612425 \tabularnewline
30 & 35043 & 55242.3927448331 & -20199.3927448331 \tabularnewline
31 & 30475 & 21527.7399594715 & 8947.26004052853 \tabularnewline
32 & 28309 & 24138.5864008945 & 4170.4135991055 \tabularnewline
33 & 31394 & 24285.2183185933 & 7108.78168140668 \tabularnewline
34 & 36313 & 21883.3894359862 & 14429.6105640138 \tabularnewline
35 & 40357 & 27432.5515834812 & 12924.4484165188 \tabularnewline
36 & 38918 & 16938.5845099994 & 21979.4154900006 \tabularnewline
37 & 44368 & 54525.1967766752 & -10157.1967766752 \tabularnewline
38 & 33298 & 36445.2291981026 & -3147.2291981026 \tabularnewline
39 & 29366 & 41611.3182312758 & -12245.3182312758 \tabularnewline
40 & 28282 & 34888.7957084244 & -6606.79570842441 \tabularnewline
41 & 30943 & 34940.0914696705 & -3997.09146967054 \tabularnewline
42 & 32699 & 42882.2362591249 & -10183.2362591249 \tabularnewline
43 & 29764 & 34904.3024580426 & -5140.30245804261 \tabularnewline
44 & 25524 & 31519.9410905748 & -5995.94109057475 \tabularnewline
45 & 29807 & 33143.8406174388 & -3336.84061743884 \tabularnewline
46 & 35112 & 34999.0324079421 & 112.967592057867 \tabularnewline
47 & 32192 & 36621.4935260126 & -4429.49352601259 \tabularnewline
48 & 36214 & 29445.9666854708 & 6768.03331452919 \tabularnewline
49 & 47639 & 34999.4033551841 & 12639.5966448159 \tabularnewline
50 & 33421 & 27612.4949413278 & 5808.50505867224 \tabularnewline
51 & 28642 & 25902.7932377921 & 2739.20676220794 \tabularnewline
52 & 26996 & 25889.4319753212 & 1106.56802467881 \tabularnewline
53 & 27757 & 28915.3284121261 & -1158.32841212612 \tabularnewline
54 & 36839 & 31395.2379953971 & 5443.7620046029 \tabularnewline
55 & 33821 & 29947.6044556744 & 3873.39554432555 \tabularnewline
56 & 30839 & 26986.1620173649 & 3852.83798263506 \tabularnewline
57 & 35032 & 32876.4101043732 & 2155.58989562679 \tabularnewline
58 & 38821 & 39502.5245645302 & -681.524564530198 \tabularnewline
59 & 40347 & 37150.4669573696 & 3196.53304263038 \tabularnewline
60 & 68799 & 41571.0361414762 & 27227.9638585238 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=295374&T=2

[TABLE]
[ROW][C]Interpolation Forecasts of Exponential Smoothing[/C][/ROW]
[ROW][C]t[/C][C]Observed[/C][C]Fitted[/C][C]Residuals[/C][/ROW]
[ROW][C]13[/C][C]70170[/C][C]67335.6624934848[/C][C]2834.33750651521[/C][/ROW]
[ROW][C]14[/C][C]43949[/C][C]42806.6559671794[/C][C]1142.34403282056[/C][/ROW]
[ROW][C]15[/C][C]52333[/C][C]51716.2593668158[/C][C]616.740633184156[/C][/ROW]
[ROW][C]16[/C][C]41032[/C][C]41500.027621029[/C][C]-468.027621029032[/C][/ROW]
[ROW][C]17[/C][C]47758[/C][C]49236.2448308695[/C][C]-1478.24483086947[/C][/ROW]
[ROW][C]18[/C][C]76116[/C][C]78403.241493294[/C][C]-2287.24149329403[/C][/ROW]
[ROW][C]19[/C][C]30917[/C][C]38895.3921112922[/C][C]-7978.39211129224[/C][/ROW]
[ROW][C]20[/C][C]32996[/C][C]35096.1972138899[/C][C]-2100.19721388991[/C][/ROW]
[ROW][C]21[/C][C]31951[/C][C]39510.0504450047[/C][C]-7559.05044500469[/C][/ROW]
[ROW][C]22[/C][C]26775[/C][C]37783.734617154[/C][C]-11008.734617154[/C][/ROW]
[ROW][C]23[/C][C]30268[/C][C]33945.7869225516[/C][C]-3677.78692255155[/C][/ROW]
[ROW][C]24[/C][C]18214[/C][C]13513.2447068334[/C][C]4700.75529316659[/C][/ROW]
[ROW][C]25[/C][C]47957[/C][C]58086.8461342323[/C][C]-10129.8461342323[/C][/ROW]
[ROW][C]26[/C][C]31901[/C][C]35095.6554438181[/C][C]-3194.6554438181[/C][/ROW]
[ROW][C]27[/C][C]35559[/C][C]40795.2226771601[/C][C]-5236.22267716011[/C][/ROW]
[ROW][C]28[/C][C]30408[/C][C]31106.2356087655[/C][C]-698.235608765495[/C][/ROW]
[ROW][C]29[/C][C]30083[/C][C]35791.0876861243[/C][C]-5708.08768612425[/C][/ROW]
[ROW][C]30[/C][C]35043[/C][C]55242.3927448331[/C][C]-20199.3927448331[/C][/ROW]
[ROW][C]31[/C][C]30475[/C][C]21527.7399594715[/C][C]8947.26004052853[/C][/ROW]
[ROW][C]32[/C][C]28309[/C][C]24138.5864008945[/C][C]4170.4135991055[/C][/ROW]
[ROW][C]33[/C][C]31394[/C][C]24285.2183185933[/C][C]7108.78168140668[/C][/ROW]
[ROW][C]34[/C][C]36313[/C][C]21883.3894359862[/C][C]14429.6105640138[/C][/ROW]
[ROW][C]35[/C][C]40357[/C][C]27432.5515834812[/C][C]12924.4484165188[/C][/ROW]
[ROW][C]36[/C][C]38918[/C][C]16938.5845099994[/C][C]21979.4154900006[/C][/ROW]
[ROW][C]37[/C][C]44368[/C][C]54525.1967766752[/C][C]-10157.1967766752[/C][/ROW]
[ROW][C]38[/C][C]33298[/C][C]36445.2291981026[/C][C]-3147.2291981026[/C][/ROW]
[ROW][C]39[/C][C]29366[/C][C]41611.3182312758[/C][C]-12245.3182312758[/C][/ROW]
[ROW][C]40[/C][C]28282[/C][C]34888.7957084244[/C][C]-6606.79570842441[/C][/ROW]
[ROW][C]41[/C][C]30943[/C][C]34940.0914696705[/C][C]-3997.09146967054[/C][/ROW]
[ROW][C]42[/C][C]32699[/C][C]42882.2362591249[/C][C]-10183.2362591249[/C][/ROW]
[ROW][C]43[/C][C]29764[/C][C]34904.3024580426[/C][C]-5140.30245804261[/C][/ROW]
[ROW][C]44[/C][C]25524[/C][C]31519.9410905748[/C][C]-5995.94109057475[/C][/ROW]
[ROW][C]45[/C][C]29807[/C][C]33143.8406174388[/C][C]-3336.84061743884[/C][/ROW]
[ROW][C]46[/C][C]35112[/C][C]34999.0324079421[/C][C]112.967592057867[/C][/ROW]
[ROW][C]47[/C][C]32192[/C][C]36621.4935260126[/C][C]-4429.49352601259[/C][/ROW]
[ROW][C]48[/C][C]36214[/C][C]29445.9666854708[/C][C]6768.03331452919[/C][/ROW]
[ROW][C]49[/C][C]47639[/C][C]34999.4033551841[/C][C]12639.5966448159[/C][/ROW]
[ROW][C]50[/C][C]33421[/C][C]27612.4949413278[/C][C]5808.50505867224[/C][/ROW]
[ROW][C]51[/C][C]28642[/C][C]25902.7932377921[/C][C]2739.20676220794[/C][/ROW]
[ROW][C]52[/C][C]26996[/C][C]25889.4319753212[/C][C]1106.56802467881[/C][/ROW]
[ROW][C]53[/C][C]27757[/C][C]28915.3284121261[/C][C]-1158.32841212612[/C][/ROW]
[ROW][C]54[/C][C]36839[/C][C]31395.2379953971[/C][C]5443.7620046029[/C][/ROW]
[ROW][C]55[/C][C]33821[/C][C]29947.6044556744[/C][C]3873.39554432555[/C][/ROW]
[ROW][C]56[/C][C]30839[/C][C]26986.1620173649[/C][C]3852.83798263506[/C][/ROW]
[ROW][C]57[/C][C]35032[/C][C]32876.4101043732[/C][C]2155.58989562679[/C][/ROW]
[ROW][C]58[/C][C]38821[/C][C]39502.5245645302[/C][C]-681.524564530198[/C][/ROW]
[ROW][C]59[/C][C]40347[/C][C]37150.4669573696[/C][C]3196.53304263038[/C][/ROW]
[ROW][C]60[/C][C]68799[/C][C]41571.0361414762[/C][C]27227.9638585238[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=295374&T=2

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

As an alternative you can also use a QR Code:  

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

Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
137017067335.66249348482834.33750651521
144394942806.65596717941142.34403282056
155233351716.2593668158616.740633184156
164103241500.027621029-468.027621029032
174775849236.2448308695-1478.24483086947
187611678403.241493294-2287.24149329403
193091738895.3921112922-7978.39211129224
203299635096.1972138899-2100.19721388991
213195139510.0504450047-7559.05044500469
222677537783.734617154-11008.734617154
233026833945.7869225516-3677.78692255155
241821413513.24470683344700.75529316659
254795758086.8461342323-10129.8461342323
263190135095.6554438181-3194.6554438181
273555940795.2226771601-5236.22267716011
283040831106.2356087655-698.235608765495
293008335791.0876861243-5708.08768612425
303504355242.3927448331-20199.3927448331
313047521527.73995947158947.26004052853
322830924138.58640089454170.4135991055
333139424285.21831859337108.78168140668
343631321883.389435986214429.6105640138
354035727432.551583481212924.4484165188
363891816938.584509999421979.4154900006
374436854525.1967766752-10157.1967766752
383329836445.2291981026-3147.2291981026
392936641611.3182312758-12245.3182312758
402828234888.7957084244-6606.79570842441
413094334940.0914696705-3997.09146967054
423269942882.2362591249-10183.2362591249
432976434904.3024580426-5140.30245804261
442552431519.9410905748-5995.94109057475
452980733143.8406174388-3336.84061743884
463511234999.0324079421112.967592057867
473219236621.4935260126-4429.49352601259
483621429445.96668547086768.03331452919
494763934999.403355184112639.5966448159
503342127612.49494132785808.50505867224
512864225902.79323779212739.20676220794
522699625889.43197532121106.56802467881
532775728915.3284121261-1158.32841212612
543683931395.23799539715443.7620046029
553382129947.60445567443873.39554432555
563083926986.16201736493852.83798263506
573503232876.41010437322155.58989562679
583882139502.5245645302-681.524564530198
594034737150.46695736963196.53304263038
606879941571.036141476227227.9638585238







Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
6157677.713434384940833.113796456974522.3130723128
6239871.780329218222946.733467822656796.8271906137
6334067.75553655517035.566556141251099.9445169689
6432249.510157925815069.55927806749429.4610377846
6533659.284944195916232.723924205351085.8459641865
6644096.346684711825895.564087800762297.1292816229
6740129.187807695421915.249884519258343.1257308717
6836163.747613825417968.108198904954359.3870287459
6940964.304442603922059.49519220859869.1136929998
7045741.307990040125970.269475736365512.3465043441
7147252.861084798726904.3954739867601.3266956174
7274427.690046731155338.781412920593516.5986805417

\begin{tabular}{lllllllll}
\hline
Extrapolation Forecasts of Exponential Smoothing \tabularnewline
t & Forecast & 95% Lower Bound & 95% Upper Bound \tabularnewline
61 & 57677.7134343849 & 40833.1137964569 & 74522.3130723128 \tabularnewline
62 & 39871.7803292182 & 22946.7334678226 & 56796.8271906137 \tabularnewline
63 & 34067.755536555 & 17035.5665561412 & 51099.9445169689 \tabularnewline
64 & 32249.5101579258 & 15069.559278067 & 49429.4610377846 \tabularnewline
65 & 33659.2849441959 & 16232.7239242053 & 51085.8459641865 \tabularnewline
66 & 44096.3466847118 & 25895.5640878007 & 62297.1292816229 \tabularnewline
67 & 40129.1878076954 & 21915.2498845192 & 58343.1257308717 \tabularnewline
68 & 36163.7476138254 & 17968.1081989049 & 54359.3870287459 \tabularnewline
69 & 40964.3044426039 & 22059.495192208 & 59869.1136929998 \tabularnewline
70 & 45741.3079900401 & 25970.2694757363 & 65512.3465043441 \tabularnewline
71 & 47252.8610847987 & 26904.39547398 & 67601.3266956174 \tabularnewline
72 & 74427.6900467311 & 55338.7814129205 & 93516.5986805417 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=295374&T=3

[TABLE]
[ROW][C]Extrapolation Forecasts of Exponential Smoothing[/C][/ROW]
[ROW][C]t[/C][C]Forecast[/C][C]95% Lower Bound[/C][C]95% Upper Bound[/C][/ROW]
[ROW][C]61[/C][C]57677.7134343849[/C][C]40833.1137964569[/C][C]74522.3130723128[/C][/ROW]
[ROW][C]62[/C][C]39871.7803292182[/C][C]22946.7334678226[/C][C]56796.8271906137[/C][/ROW]
[ROW][C]63[/C][C]34067.755536555[/C][C]17035.5665561412[/C][C]51099.9445169689[/C][/ROW]
[ROW][C]64[/C][C]32249.5101579258[/C][C]15069.559278067[/C][C]49429.4610377846[/C][/ROW]
[ROW][C]65[/C][C]33659.2849441959[/C][C]16232.7239242053[/C][C]51085.8459641865[/C][/ROW]
[ROW][C]66[/C][C]44096.3466847118[/C][C]25895.5640878007[/C][C]62297.1292816229[/C][/ROW]
[ROW][C]67[/C][C]40129.1878076954[/C][C]21915.2498845192[/C][C]58343.1257308717[/C][/ROW]
[ROW][C]68[/C][C]36163.7476138254[/C][C]17968.1081989049[/C][C]54359.3870287459[/C][/ROW]
[ROW][C]69[/C][C]40964.3044426039[/C][C]22059.495192208[/C][C]59869.1136929998[/C][/ROW]
[ROW][C]70[/C][C]45741.3079900401[/C][C]25970.2694757363[/C][C]65512.3465043441[/C][/ROW]
[ROW][C]71[/C][C]47252.8610847987[/C][C]26904.39547398[/C][C]67601.3266956174[/C][/ROW]
[ROW][C]72[/C][C]74427.6900467311[/C][C]55338.7814129205[/C][C]93516.5986805417[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=295374&T=3

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

As an alternative you can also use a QR Code:  

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

Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
6157677.713434384940833.113796456974522.3130723128
6239871.780329218222946.733467822656796.8271906137
6334067.75553655517035.566556141251099.9445169689
6432249.510157925815069.55927806749429.4610377846
6533659.284944195916232.723924205351085.8459641865
6644096.346684711825895.564087800762297.1292816229
6740129.187807695421915.249884519258343.1257308717
6836163.747613825417968.108198904954359.3870287459
6940964.304442603922059.49519220859869.1136929998
7045741.307990040125970.269475736365512.3465043441
7147252.861084798726904.3954739867601.3266956174
7274427.690046731155338.781412920593516.5986805417



Parameters (Session):
par1 = 12 ; par2 = Triple ; par3 = multiplicative ;
Parameters (R input):
par1 = 12 ; par2 = Triple ; par3 = multiplicative ;
R code (references can be found in the software module):
par3 <- 'additive'
par2 <- 'Double'
par1 <- '12'
par1 <- as.numeric(par1)
if (par2 == 'Single') K <- 1
if (par2 == 'Double') K <- 2
if (par2 == 'Triple') K <- par1
nx <- length(x)
nxmK <- nx - K
x <- ts(x, frequency = par1)
if (par2 == 'Single') fit <- HoltWinters(x, gamma=F, beta=F)
if (par2 == 'Double') fit <- HoltWinters(x, gamma=F)
if (par2 == 'Triple') fit <- HoltWinters(x, seasonal=par3)
fit
myresid <- x - fit$fitted[,'xhat']
bitmap(file='test1.png')
op <- par(mfrow=c(2,1))
plot(fit,ylab='Observed (black) / Fitted (red)',main='Interpolation Fit of Exponential Smoothing')
plot(myresid,ylab='Residuals',main='Interpolation Prediction Errors')
par(op)
dev.off()
bitmap(file='test2.png')
p <- predict(fit, par1, prediction.interval=TRUE)
np <- length(p[,1])
plot(fit,p,ylab='Observed (black) / Fitted (red)',main='Extrapolation Fit of Exponential Smoothing')
dev.off()
bitmap(file='test3.png')
op <- par(mfrow = c(2,2))
acf(as.numeric(myresid),lag.max = nx/2,main='Residual ACF')
spectrum(myresid,main='Residals Periodogram')
cpgram(myresid,main='Residal Cumulative Periodogram')
qqnorm(myresid,main='Residual Normal QQ Plot')
qqline(myresid)
par(op)
dev.off()
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Estimated Parameters of Exponential Smoothing',2,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Parameter',header=TRUE)
a<-table.element(a,'Value',header=TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'alpha',header=TRUE)
a<-table.element(a,fit$alpha)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'beta',header=TRUE)
a<-table.element(a,fit$beta)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'gamma',header=TRUE)
a<-table.element(a,fit$gamma)
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,'Interpolation Forecasts of Exponential Smoothing',4,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'t',header=TRUE)
a<-table.element(a,'Observed',header=TRUE)
a<-table.element(a,'Fitted',header=TRUE)
a<-table.element(a,'Residuals',header=TRUE)
a<-table.row.end(a)
for (i in 1:nxmK) {
a<-table.row.start(a)
a<-table.element(a,i+K,header=TRUE)
a<-table.element(a,x[i+K])
a<-table.element(a,fit$fitted[i,'xhat'])
a<-table.element(a,myresid[i])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable1.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Extrapolation Forecasts of Exponential Smoothing',4,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'t',header=TRUE)
a<-table.element(a,'Forecast',header=TRUE)
a<-table.element(a,'95% Lower Bound',header=TRUE)
a<-table.element(a,'95% Upper Bound',header=TRUE)
a<-table.row.end(a)
for (i in 1:np) {
a<-table.row.start(a)
a<-table.element(a,nx+i,header=TRUE)
a<-table.element(a,p[i,'fit'])
a<-table.element(a,p[i,'lwr'])
a<-table.element(a,p[i,'upr'])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable2.tab')