Free Statistics

of Irreproducible Research!

Author's title

Author*The author of this computation has been verified*
R Software Modulerwasp_exponentialsmoothing.wasp
Title produced by softwareExponential Smoothing
Date of computationTue, 13 Dec 2016 22:39:55 +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/Dec/13/t1481665221zl8llhfwfony54s.htm/, Retrieved Sun, 05 May 2024 08:03:40 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=299244, Retrieved Sun, 05 May 2024 08:03:40 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact56
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-       [Exponential Smoothing] [] [2016-12-13 21:39:55] [130d73899007e5ff8a4f636b9bcfb397] [Current]
Feedback Forum

Post a new message
Dataseries X:
4650
4800
3500
3850
9100
4400
8500
6000
2850
7450
6000
4950
6400
5550
6900
9900
6400
8000
5450
6800
6150
8600
8700
4000
8300
4950
4100
4200
6600
8050
8950
10850
3750
6800
3650
3600
3400
3400
3750
5100
3700
4850
7700
2800
5750
6200
5150
4300
4500
3450
5600




Summary of computational transaction
Raw Input view raw input (R code)
Raw Outputview raw output of R engine
Computing time1 seconds
R ServerBig Analytics Cloud Computing Center

\begin{tabular}{lllllllll}
\hline
Summary of computational transaction \tabularnewline
Raw Input view raw input (R code)  \tabularnewline
Raw Outputview raw output of R engine  \tabularnewline
Computing time1 seconds \tabularnewline
R ServerBig Analytics Cloud Computing Center \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=299244&T=0

[TABLE]
[ROW]
Summary of computational transaction[/C][/ROW] [ROW]Raw Input[/C] view raw input (R code) [/C][/ROW] [ROW]Raw Output[/C]view raw output of R engine [/C][/ROW] [ROW]Computing time[/C]1 seconds[/C][/ROW] [ROW]R Server[/C]Big Analytics Cloud Computing Center[/C][/ROW] [/TABLE] Source: https://freestatistics.org/blog/index.php?pk=299244&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=299244&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 Input view raw input (R code)
Raw Outputview raw output of R engine
Computing time1 seconds
R ServerBig Analytics Cloud Computing Center







Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.167988555665186
betaFALSE
gammaFALSE

\begin{tabular}{lllllllll}
\hline
Estimated Parameters of Exponential Smoothing \tabularnewline
Parameter & Value \tabularnewline
alpha & 0.167988555665186 \tabularnewline
beta & FALSE \tabularnewline
gamma & FALSE \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=299244&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.167988555665186[/C][/ROW]
[ROW][C]beta[/C][C]FALSE[/C][/ROW]
[ROW][C]gamma[/C][C]FALSE[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=299244&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=299244&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.167988555665186
betaFALSE
gammaFALSE







Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
248004650150
335004675.19828334978-1175.19828334978
438504477.77842110964-627.778421109642
591004372.318830869664727.68116913034
644005166.51516211737-766.515162117365
785005037.74938713783462.2506128622
860005619.36786694343380.632133056572
928505683.30970921536-2833.30970921536
1074505207.346103412122242.65389658788
1160005584.08629235682415.913707643178
1249505653.95503538515-703.955035385152
1364005535.69864573757864.301354262435
1455505680.89138189958-130.891381899575
1569005658.903127705241241.09687229476
1699005867.393198722624032.60680127738
1764006544.82499083481-144.824990834813
1880006520.496049800251479.50395019975
1954506769.03578149524-1319.03578149524
2068006547.45286569116252.547134308843
2161506589.87789402108-439.877894021081
2286006515.983441935442084.01655806456
2387006866.074373507031833.92562649297
2440007174.15289069896-3174.15289069896
2583006640.931531129961659.06846887004
2649506919.63604696509-1969.63604696509
2741006588.75973224934-2488.75973224934
2842006170.6765794311-1970.6765794311
2966005839.62546716926760.37453283074
3080505967.359686704092082.64031329591
3189506317.219424904762632.78057509524
32108506759.496431098364090.50356890164
3337507446.65421758144-3696.65421758144
3468006825.65861477631-25.6586147763137
3536506821.34826113967-3171.34826113967
3636006288.59804723952-2688.59804723952
3734005836.94434451951-2436.94434451951
3834005427.56558384724-2027.56558384724
3937505086.9577699003-1336.9577699003
4051004862.3641651494237.6358348506
4137004902.28426582024-1202.28426582024
4248504700.31426850612149.685731493879
4377004725.459758343462974.54024165654
4428005225.14847730732-2425.14847730732
4557504817.75128733084932.248712669163
4662004974.358402092861225.64159790714
4751505180.25216388845-30.25216388845
4843005175.17014657108-875.170146571082
4945005028.15157768732-528.151577687318
5034504939.42815697934-1489.42815697934
5156004689.22127212132910.778727878683

\begin{tabular}{lllllllll}
\hline
Interpolation Forecasts of Exponential Smoothing \tabularnewline
t & Observed & Fitted & Residuals \tabularnewline
2 & 4800 & 4650 & 150 \tabularnewline
3 & 3500 & 4675.19828334978 & -1175.19828334978 \tabularnewline
4 & 3850 & 4477.77842110964 & -627.778421109642 \tabularnewline
5 & 9100 & 4372.31883086966 & 4727.68116913034 \tabularnewline
6 & 4400 & 5166.51516211737 & -766.515162117365 \tabularnewline
7 & 8500 & 5037.7493871378 & 3462.2506128622 \tabularnewline
8 & 6000 & 5619.36786694343 & 380.632133056572 \tabularnewline
9 & 2850 & 5683.30970921536 & -2833.30970921536 \tabularnewline
10 & 7450 & 5207.34610341212 & 2242.65389658788 \tabularnewline
11 & 6000 & 5584.08629235682 & 415.913707643178 \tabularnewline
12 & 4950 & 5653.95503538515 & -703.955035385152 \tabularnewline
13 & 6400 & 5535.69864573757 & 864.301354262435 \tabularnewline
14 & 5550 & 5680.89138189958 & -130.891381899575 \tabularnewline
15 & 6900 & 5658.90312770524 & 1241.09687229476 \tabularnewline
16 & 9900 & 5867.39319872262 & 4032.60680127738 \tabularnewline
17 & 6400 & 6544.82499083481 & -144.824990834813 \tabularnewline
18 & 8000 & 6520.49604980025 & 1479.50395019975 \tabularnewline
19 & 5450 & 6769.03578149524 & -1319.03578149524 \tabularnewline
20 & 6800 & 6547.45286569116 & 252.547134308843 \tabularnewline
21 & 6150 & 6589.87789402108 & -439.877894021081 \tabularnewline
22 & 8600 & 6515.98344193544 & 2084.01655806456 \tabularnewline
23 & 8700 & 6866.07437350703 & 1833.92562649297 \tabularnewline
24 & 4000 & 7174.15289069896 & -3174.15289069896 \tabularnewline
25 & 8300 & 6640.93153112996 & 1659.06846887004 \tabularnewline
26 & 4950 & 6919.63604696509 & -1969.63604696509 \tabularnewline
27 & 4100 & 6588.75973224934 & -2488.75973224934 \tabularnewline
28 & 4200 & 6170.6765794311 & -1970.6765794311 \tabularnewline
29 & 6600 & 5839.62546716926 & 760.37453283074 \tabularnewline
30 & 8050 & 5967.35968670409 & 2082.64031329591 \tabularnewline
31 & 8950 & 6317.21942490476 & 2632.78057509524 \tabularnewline
32 & 10850 & 6759.49643109836 & 4090.50356890164 \tabularnewline
33 & 3750 & 7446.65421758144 & -3696.65421758144 \tabularnewline
34 & 6800 & 6825.65861477631 & -25.6586147763137 \tabularnewline
35 & 3650 & 6821.34826113967 & -3171.34826113967 \tabularnewline
36 & 3600 & 6288.59804723952 & -2688.59804723952 \tabularnewline
37 & 3400 & 5836.94434451951 & -2436.94434451951 \tabularnewline
38 & 3400 & 5427.56558384724 & -2027.56558384724 \tabularnewline
39 & 3750 & 5086.9577699003 & -1336.9577699003 \tabularnewline
40 & 5100 & 4862.3641651494 & 237.6358348506 \tabularnewline
41 & 3700 & 4902.28426582024 & -1202.28426582024 \tabularnewline
42 & 4850 & 4700.31426850612 & 149.685731493879 \tabularnewline
43 & 7700 & 4725.45975834346 & 2974.54024165654 \tabularnewline
44 & 2800 & 5225.14847730732 & -2425.14847730732 \tabularnewline
45 & 5750 & 4817.75128733084 & 932.248712669163 \tabularnewline
46 & 6200 & 4974.35840209286 & 1225.64159790714 \tabularnewline
47 & 5150 & 5180.25216388845 & -30.25216388845 \tabularnewline
48 & 4300 & 5175.17014657108 & -875.170146571082 \tabularnewline
49 & 4500 & 5028.15157768732 & -528.151577687318 \tabularnewline
50 & 3450 & 4939.42815697934 & -1489.42815697934 \tabularnewline
51 & 5600 & 4689.22127212132 & 910.778727878683 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=299244&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]2[/C][C]4800[/C][C]4650[/C][C]150[/C][/ROW]
[ROW][C]3[/C][C]3500[/C][C]4675.19828334978[/C][C]-1175.19828334978[/C][/ROW]
[ROW][C]4[/C][C]3850[/C][C]4477.77842110964[/C][C]-627.778421109642[/C][/ROW]
[ROW][C]5[/C][C]9100[/C][C]4372.31883086966[/C][C]4727.68116913034[/C][/ROW]
[ROW][C]6[/C][C]4400[/C][C]5166.51516211737[/C][C]-766.515162117365[/C][/ROW]
[ROW][C]7[/C][C]8500[/C][C]5037.7493871378[/C][C]3462.2506128622[/C][/ROW]
[ROW][C]8[/C][C]6000[/C][C]5619.36786694343[/C][C]380.632133056572[/C][/ROW]
[ROW][C]9[/C][C]2850[/C][C]5683.30970921536[/C][C]-2833.30970921536[/C][/ROW]
[ROW][C]10[/C][C]7450[/C][C]5207.34610341212[/C][C]2242.65389658788[/C][/ROW]
[ROW][C]11[/C][C]6000[/C][C]5584.08629235682[/C][C]415.913707643178[/C][/ROW]
[ROW][C]12[/C][C]4950[/C][C]5653.95503538515[/C][C]-703.955035385152[/C][/ROW]
[ROW][C]13[/C][C]6400[/C][C]5535.69864573757[/C][C]864.301354262435[/C][/ROW]
[ROW][C]14[/C][C]5550[/C][C]5680.89138189958[/C][C]-130.891381899575[/C][/ROW]
[ROW][C]15[/C][C]6900[/C][C]5658.90312770524[/C][C]1241.09687229476[/C][/ROW]
[ROW][C]16[/C][C]9900[/C][C]5867.39319872262[/C][C]4032.60680127738[/C][/ROW]
[ROW][C]17[/C][C]6400[/C][C]6544.82499083481[/C][C]-144.824990834813[/C][/ROW]
[ROW][C]18[/C][C]8000[/C][C]6520.49604980025[/C][C]1479.50395019975[/C][/ROW]
[ROW][C]19[/C][C]5450[/C][C]6769.03578149524[/C][C]-1319.03578149524[/C][/ROW]
[ROW][C]20[/C][C]6800[/C][C]6547.45286569116[/C][C]252.547134308843[/C][/ROW]
[ROW][C]21[/C][C]6150[/C][C]6589.87789402108[/C][C]-439.877894021081[/C][/ROW]
[ROW][C]22[/C][C]8600[/C][C]6515.98344193544[/C][C]2084.01655806456[/C][/ROW]
[ROW][C]23[/C][C]8700[/C][C]6866.07437350703[/C][C]1833.92562649297[/C][/ROW]
[ROW][C]24[/C][C]4000[/C][C]7174.15289069896[/C][C]-3174.15289069896[/C][/ROW]
[ROW][C]25[/C][C]8300[/C][C]6640.93153112996[/C][C]1659.06846887004[/C][/ROW]
[ROW][C]26[/C][C]4950[/C][C]6919.63604696509[/C][C]-1969.63604696509[/C][/ROW]
[ROW][C]27[/C][C]4100[/C][C]6588.75973224934[/C][C]-2488.75973224934[/C][/ROW]
[ROW][C]28[/C][C]4200[/C][C]6170.6765794311[/C][C]-1970.6765794311[/C][/ROW]
[ROW][C]29[/C][C]6600[/C][C]5839.62546716926[/C][C]760.37453283074[/C][/ROW]
[ROW][C]30[/C][C]8050[/C][C]5967.35968670409[/C][C]2082.64031329591[/C][/ROW]
[ROW][C]31[/C][C]8950[/C][C]6317.21942490476[/C][C]2632.78057509524[/C][/ROW]
[ROW][C]32[/C][C]10850[/C][C]6759.49643109836[/C][C]4090.50356890164[/C][/ROW]
[ROW][C]33[/C][C]3750[/C][C]7446.65421758144[/C][C]-3696.65421758144[/C][/ROW]
[ROW][C]34[/C][C]6800[/C][C]6825.65861477631[/C][C]-25.6586147763137[/C][/ROW]
[ROW][C]35[/C][C]3650[/C][C]6821.34826113967[/C][C]-3171.34826113967[/C][/ROW]
[ROW][C]36[/C][C]3600[/C][C]6288.59804723952[/C][C]-2688.59804723952[/C][/ROW]
[ROW][C]37[/C][C]3400[/C][C]5836.94434451951[/C][C]-2436.94434451951[/C][/ROW]
[ROW][C]38[/C][C]3400[/C][C]5427.56558384724[/C][C]-2027.56558384724[/C][/ROW]
[ROW][C]39[/C][C]3750[/C][C]5086.9577699003[/C][C]-1336.9577699003[/C][/ROW]
[ROW][C]40[/C][C]5100[/C][C]4862.3641651494[/C][C]237.6358348506[/C][/ROW]
[ROW][C]41[/C][C]3700[/C][C]4902.28426582024[/C][C]-1202.28426582024[/C][/ROW]
[ROW][C]42[/C][C]4850[/C][C]4700.31426850612[/C][C]149.685731493879[/C][/ROW]
[ROW][C]43[/C][C]7700[/C][C]4725.45975834346[/C][C]2974.54024165654[/C][/ROW]
[ROW][C]44[/C][C]2800[/C][C]5225.14847730732[/C][C]-2425.14847730732[/C][/ROW]
[ROW][C]45[/C][C]5750[/C][C]4817.75128733084[/C][C]932.248712669163[/C][/ROW]
[ROW][C]46[/C][C]6200[/C][C]4974.35840209286[/C][C]1225.64159790714[/C][/ROW]
[ROW][C]47[/C][C]5150[/C][C]5180.25216388845[/C][C]-30.25216388845[/C][/ROW]
[ROW][C]48[/C][C]4300[/C][C]5175.17014657108[/C][C]-875.170146571082[/C][/ROW]
[ROW][C]49[/C][C]4500[/C][C]5028.15157768732[/C][C]-528.151577687318[/C][/ROW]
[ROW][C]50[/C][C]3450[/C][C]4939.42815697934[/C][C]-1489.42815697934[/C][/ROW]
[ROW][C]51[/C][C]5600[/C][C]4689.22127212132[/C][C]910.778727878683[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=299244&T=2

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=299244&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
248004650150
335004675.19828334978-1175.19828334978
438504477.77842110964-627.778421109642
591004372.318830869664727.68116913034
644005166.51516211737-766.515162117365
785005037.74938713783462.2506128622
860005619.36786694343380.632133056572
928505683.30970921536-2833.30970921536
1074505207.346103412122242.65389658788
1160005584.08629235682415.913707643178
1249505653.95503538515-703.955035385152
1364005535.69864573757864.301354262435
1455505680.89138189958-130.891381899575
1569005658.903127705241241.09687229476
1699005867.393198722624032.60680127738
1764006544.82499083481-144.824990834813
1880006520.496049800251479.50395019975
1954506769.03578149524-1319.03578149524
2068006547.45286569116252.547134308843
2161506589.87789402108-439.877894021081
2286006515.983441935442084.01655806456
2387006866.074373507031833.92562649297
2440007174.15289069896-3174.15289069896
2583006640.931531129961659.06846887004
2649506919.63604696509-1969.63604696509
2741006588.75973224934-2488.75973224934
2842006170.6765794311-1970.6765794311
2966005839.62546716926760.37453283074
3080505967.359686704092082.64031329591
3189506317.219424904762632.78057509524
32108506759.496431098364090.50356890164
3337507446.65421758144-3696.65421758144
3468006825.65861477631-25.6586147763137
3536506821.34826113967-3171.34826113967
3636006288.59804723952-2688.59804723952
3734005836.94434451951-2436.94434451951
3834005427.56558384724-2027.56558384724
3937505086.9577699003-1336.9577699003
4051004862.3641651494237.6358348506
4137004902.28426582024-1202.28426582024
4248504700.31426850612149.685731493879
4377004725.459758343462974.54024165654
4428005225.14847730732-2425.14847730732
4557504817.75128733084932.248712669163
4662004974.358402092861225.64159790714
4751505180.25216388845-30.25216388845
4843005175.17014657108-875.170146571082
4945005028.15157768732-528.151577687318
5034504939.42815697934-1489.42815697934
5156004689.22127212132910.778727878683







Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
524842.22167514823863.5421286338368820.90122166263
534842.22167514823807.7932265302428876.65012376622
544842.22167514823752.8042496236238931.63910067284
554842.22167514823698.5449438683328985.89840642813
564842.22167514823644.9870109298219039.45633936664
574842.22167514823592.1039356399729092.33941465649
584842.22167514823539.8708325449749144.57251775149
594842.22167514823488.2643090254179196.17904127105
604842.22167514823437.262342852279247.1810074442
614842.22167514823386.8441723604569297.59917793601
624842.22167514823336.9901976863259347.45315261014
634842.22167514823287.6818917365469396.76145855992

\begin{tabular}{lllllllll}
\hline
Extrapolation Forecasts of Exponential Smoothing \tabularnewline
t & Forecast & 95% Lower Bound & 95% Upper Bound \tabularnewline
52 & 4842.22167514823 & 863.542128633836 & 8820.90122166263 \tabularnewline
53 & 4842.22167514823 & 807.793226530242 & 8876.65012376622 \tabularnewline
54 & 4842.22167514823 & 752.804249623623 & 8931.63910067284 \tabularnewline
55 & 4842.22167514823 & 698.544943868332 & 8985.89840642813 \tabularnewline
56 & 4842.22167514823 & 644.987010929821 & 9039.45633936664 \tabularnewline
57 & 4842.22167514823 & 592.103935639972 & 9092.33941465649 \tabularnewline
58 & 4842.22167514823 & 539.870832544974 & 9144.57251775149 \tabularnewline
59 & 4842.22167514823 & 488.264309025417 & 9196.17904127105 \tabularnewline
60 & 4842.22167514823 & 437.26234285227 & 9247.1810074442 \tabularnewline
61 & 4842.22167514823 & 386.844172360456 & 9297.59917793601 \tabularnewline
62 & 4842.22167514823 & 336.990197686325 & 9347.45315261014 \tabularnewline
63 & 4842.22167514823 & 287.681891736546 & 9396.76145855992 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=299244&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]52[/C][C]4842.22167514823[/C][C]863.542128633836[/C][C]8820.90122166263[/C][/ROW]
[ROW][C]53[/C][C]4842.22167514823[/C][C]807.793226530242[/C][C]8876.65012376622[/C][/ROW]
[ROW][C]54[/C][C]4842.22167514823[/C][C]752.804249623623[/C][C]8931.63910067284[/C][/ROW]
[ROW][C]55[/C][C]4842.22167514823[/C][C]698.544943868332[/C][C]8985.89840642813[/C][/ROW]
[ROW][C]56[/C][C]4842.22167514823[/C][C]644.987010929821[/C][C]9039.45633936664[/C][/ROW]
[ROW][C]57[/C][C]4842.22167514823[/C][C]592.103935639972[/C][C]9092.33941465649[/C][/ROW]
[ROW][C]58[/C][C]4842.22167514823[/C][C]539.870832544974[/C][C]9144.57251775149[/C][/ROW]
[ROW][C]59[/C][C]4842.22167514823[/C][C]488.264309025417[/C][C]9196.17904127105[/C][/ROW]
[ROW][C]60[/C][C]4842.22167514823[/C][C]437.26234285227[/C][C]9247.1810074442[/C][/ROW]
[ROW][C]61[/C][C]4842.22167514823[/C][C]386.844172360456[/C][C]9297.59917793601[/C][/ROW]
[ROW][C]62[/C][C]4842.22167514823[/C][C]336.990197686325[/C][C]9347.45315261014[/C][/ROW]
[ROW][C]63[/C][C]4842.22167514823[/C][C]287.681891736546[/C][C]9396.76145855992[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=299244&T=3

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=299244&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
524842.22167514823863.5421286338368820.90122166263
534842.22167514823807.7932265302428876.65012376622
544842.22167514823752.8042496236238931.63910067284
554842.22167514823698.5449438683328985.89840642813
564842.22167514823644.9870109298219039.45633936664
574842.22167514823592.1039356399729092.33941465649
584842.22167514823539.8708325449749144.57251775149
594842.22167514823488.2643090254179196.17904127105
604842.22167514823437.262342852279247.1810074442
614842.22167514823386.8441723604569297.59917793601
624842.22167514823336.9901976863259347.45315261014
634842.22167514823287.6818917365469396.76145855992



Parameters (Session):
par1 = 12 ; par2 = 12 ; par3 = BFGS ;
Parameters (R input):
par1 = 12 ; par2 = Single ; par3 = additive ; par4 = 12 ;
R code (references can be found in the software module):
par1 <- as.numeric(par1)
par4 <- as.numeric(par4)
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, par4, 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')